diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-07-28 17:13:38 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-07-28 17:13:38 +0000 |
commit | 6d06ed1a9e25683755b215ed1c89fde2fadbd797 (patch) | |
tree | 8715bfaec73f9a15b5a36372e3a0bcf2098200eb /src | |
parent | 4f22db0f87aac488c28054e59f17745035658765 (diff) |
Tidyup
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4580 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r-- | src/command_parse.cpp | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/command_parse.cpp b/src/command_parse.cpp index 157162bce..10fe6e1ee 100644 --- a/src/command_parse.cpp +++ b/src/command_parse.cpp @@ -250,16 +250,10 @@ void CommandParser::ProcessCommand(userrec *user, std::string &cmd) } if (items < cm->second->min_params) { + WriteServ(user->fd,"461 %s %s :Not enough parameters.", user->nick, command.c_str()); /* If syntax is given, display this as the 461 reply */ - if (cm->second->syntax.length()) - { - WriteServ(user->fd,"461 %s %s :Not enough parameters.", user->nick, command.c_str()); - /* Use RPL_TEXT for this */ - if (Config->SyntaxHints) - WriteServ(user->fd,"304 %s :SYNTAX %s %s", user->nick, cm->second->command.c_str(), cm->second->syntax.c_str()); - } - else - WriteServ(user->fd,"461 %s %s :Not enough parameters", user->nick, command.c_str()); + if ((Config->SyntaxHints) && (cm->second->syntax.length())) + WriteServ(user->fd,"304 %s :SYNTAX %s %s", user->nick, cm->second->command.c_str(), cm->second->syntax.c_str()); return; } if ((user->registered == REG_ALL) || (cm->second == command_user) || (cm->second == command_nick) || (cm->second == command_pass)) |