aboutsummaryrefslogtreecommitdiff
path: root/src/command_parse.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/command_parse.cpp')
-rw-r--r--src/command_parse.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/command_parse.cpp b/src/command_parse.cpp
index 028378eb4..dda2d2edd 100644
--- a/src/command_parse.cpp
+++ b/src/command_parse.cpp
@@ -211,7 +211,7 @@ void CommandParser::ProcessCommand(LocalUser* user, std::string& command, Comman
handler = GetHandler(command);
if (!handler)
{
- if (user->registered == REG_ALL)
+ if (user->IsFullyConnected())
user->WriteNumeric(ERR_UNKNOWNCOMMAND, command, "Unknown command");
ServerInstance->stats.Unknown++;
@@ -290,7 +290,7 @@ void CommandParser::ProcessCommand(LocalUser* user, std::string& command, Comman
case CmdAccess::SERVER:
{
- if (user->registered == REG_ALL)
+ if (user->IsFullyConnected())
user->WriteNumeric(ERR_UNKNOWNCOMMAND, command, "Unknown command");
ServerInstance->stats.Unknown++;
@@ -311,7 +311,7 @@ void CommandParser::ProcessCommand(LocalUser* user, std::string& command, Comman
return;
}
- if ((user->registered != REG_ALL) && (!handler->works_before_reg))
+ if (!user->IsFullyConnected() && !handler->works_before_reg)
{
user->CommandFloodPenalty += failpenalty;
handler->TellNotRegistered(user, command_p);