summaryrefslogtreecommitdiff
path: root/modules/core/ns_set_autoop.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/core/ns_set_autoop.cpp')
-rw-r--r--modules/core/ns_set_autoop.cpp27
1 files changed, 13 insertions, 14 deletions
diff --git a/modules/core/ns_set_autoop.cpp b/modules/core/ns_set_autoop.cpp
index f99060fa6..9ba6fb5a3 100644
--- a/modules/core/ns_set_autoop.cpp
+++ b/modules/core/ns_set_autoop.cpp
@@ -22,7 +22,6 @@ class CommandNSSetAutoOp : public Command
CommandReturn Execute(CommandSource &source, const std::vector<Anope::string> &params)
{
- User *u = source.u;
NickAlias *na = findnick(params[0]);
if (!na)
throw CoreException("NULL na in CommandNSSetAutoOp");
@@ -41,25 +40,25 @@ class CommandNSSetAutoOp : public Command
source.Reply(NICK_SASET_AUTOOP_OFF, nc->display.c_str());
}
else
- this->OnSyntaxError(u, "AUTOOP");
+ this->OnSyntaxError(source, "AUTOOP");
return MOD_CONT;
}
- bool OnHelp(User *u, const Anope::string &)
+ bool OnHelp(CommandSource &source, const Anope::string &)
{
- u->SendMessage(NickServ, NICK_HELP_SET_AUTOOP);
+ source.Reply(NICK_HELP_SET_AUTOOP);
return true;
}
- void OnSyntaxError(User *u, const Anope::string &)
+ void OnSyntaxError(CommandSource &source, const Anope::string &)
{
- SyntaxError(NickServ, u, "SET AUTOOP", NICK_SET_AUTOOP_SYNTAX);
+ SyntaxError(source, "SET AUTOOP", NICK_SET_AUTOOP_SYNTAX);
}
- void OnServHelp(User *u)
+ void OnServHelp(CommandSource &source)
{
- u->SendMessage(NickServ, NICK_HELP_CMD_SET_AUTOOP);
+ source.Reply(NICK_HELP_CMD_SET_AUTOOP);
}
};
@@ -70,20 +69,20 @@ class CommandNSSASetAutoOp : public CommandNSSetAutoOp
{
}
- bool OnHelp(User *u, const Anope::string &)
+ bool OnHelp(CommandSource &source, const Anope::string &)
{
- u->SendMessage(NickServ, NICK_HELP_SASET_AUTOOP);
+ source.Reply(NICK_HELP_SASET_AUTOOP);
return true;
}
- void OnSyntaxError(User *u, const Anope::string &)
+ void OnSyntaxError(CommandSource &source, const Anope::string &)
{
- SyntaxError(NickServ, u, "SET AUTOOP", NICK_SASET_AUTOOP_SYNTAX);
+ SyntaxError(source, "SET AUTOOP", NICK_SASET_AUTOOP_SYNTAX);
}
- void OnServHelp(User *u)
+ void OnServHelp(CommandSource &source)
{
- u->SendMessage(NickServ, NICK_HELP_CMD_SASET_AUTOOP);
+ source.Reply(NICK_HELP_CMD_SASET_AUTOOP);
}
};