diff options
author | Adam- <Adam-@5417fbe8-f217-4b02-8779-1006273d7864> | 2009-11-11 23:43:02 +0000 |
---|---|---|
committer | Adam- <Adam-@5417fbe8-f217-4b02-8779-1006273d7864> | 2009-11-11 23:43:02 +0000 |
commit | d16f4930f462386a5ad5507e56c07ac6610ac2bb (patch) | |
tree | 4ce544024c3d45ac66ebdbf638b27b5aaf43741b /src/core/os_set.c | |
parent | 30b7e50a43a354e2eeeec66345b6469bd3424269 (diff) |
Made Command::OnSyntaxError accept a subcommand parameter, we now give syntax error messages for subcommands (eg, cs_set) instead of giving the general syntax error for the main command
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2643 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/core/os_set.c')
-rw-r--r-- | src/core/os_set.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/core/os_set.c b/src/core/os_set.c index b1e047ac8..6f7f9b03b 100644 --- a/src/core/os_set.c +++ b/src/core/os_set.c @@ -42,7 +42,7 @@ class CommandOSSet : public Command if (setting.empty()) { - this->OnSyntaxError(u); + this->OnSyntaxError(u, "IGNORE"); return MOD_CONT; } @@ -68,7 +68,7 @@ class CommandOSSet : public Command if (setting.empty()) { - this->OnSyntaxError(u); + this->OnSyntaxError(u, "READONLY"); return MOD_CONT; } @@ -99,7 +99,7 @@ class CommandOSSet : public Command if (setting.empty()) { - this->OnSyntaxError(u); + this->OnSyntaxError(u, "LOGCHAN"); return MOD_CONT; } @@ -140,7 +140,7 @@ class CommandOSSet : public Command if (setting.empty()) { - this->OnSyntaxError(u); + this->OnSyntaxError(u, "SUPERADMIN"); return MOD_CONT; } @@ -177,7 +177,7 @@ class CommandOSSet : public Command if (setting.empty()) { - this->OnSyntaxError(u); + this->OnSyntaxError(u, "DEBUG"); return MOD_CONT; } @@ -211,7 +211,7 @@ class CommandOSSet : public Command if (setting.empty()) { - this->OnSyntaxError(u); + this->OnSyntaxError(u, "NOEXPIRE"); return MOD_CONT; } @@ -284,7 +284,7 @@ class CommandOSSet : public Command return true; } - void OnSyntaxError(User *u) + void OnSyntaxError(User *u, const ci::string &subcommand) { syntax_error(s_OperServ, u, "SET", OPER_SET_SYNTAX); } |