mirror of
https://github.com/anope/anope.git
synced 2026-07-01 06:36:39 +02:00
Fix default OnSyntaxError subcommand to be the last param if its size is less than the minimum required for the command
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2645 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
+1
-1
@@ -105,7 +105,7 @@ void mod_run_cmd(char *service, User * u, CommandHash * cmdTable[], const char *
|
||||
|
||||
if (params.size() < c->MinParams)
|
||||
{
|
||||
c->OnSyntaxError(u, params.size() > 1 ? params[1].c_str() : "");
|
||||
c->OnSyntaxError(u, !params.empty() ? params[params.size() - 1] : "");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user