mirror of
https://github.com/anope/anope.git
synced 2026-07-08 11:03:14 +02:00
Send replies from fantasy commands back to the channel, this will be expanded on later
This commit is contained in:
@@ -28,18 +28,20 @@ class CommandCSSASet : public Command
|
||||
this->subcommands.clear();
|
||||
}
|
||||
|
||||
CommandReturn Execute(User *u, const std::vector<Anope::string> ¶ms)
|
||||
CommandReturn Execute(CommandSource &source, const std::vector<Anope::string> ¶ms)
|
||||
{
|
||||
User *u = source.u;
|
||||
|
||||
if (readonly)
|
||||
{
|
||||
u->SendMessage(ChanServ, CHAN_SET_DISABLED);
|
||||
source.Reply(CHAN_SET_DISABLED);
|
||||
return MOD_CONT;
|
||||
}
|
||||
|
||||
// XXX Remove after 1.9.4 release
|
||||
if (params[1].equals_ci("MLOCK"))
|
||||
{
|
||||
u->SendMessage(ChanServ, CHAN_SET_MLOCK_DEPRECATED);
|
||||
source.Reply(CHAN_SET_MLOCK_DEPRECATED);
|
||||
return MOD_CONT;
|
||||
}
|
||||
|
||||
@@ -47,7 +49,7 @@ class CommandCSSASet : public Command
|
||||
|
||||
if (c)
|
||||
{
|
||||
ChannelInfo *ci = cs_findchan(params[0]);
|
||||
ChannelInfo *ci = source.ci;
|
||||
Anope::string cmdparams = ci->name;
|
||||
for (std::vector<Anope::string>::const_iterator it = params.begin() + 2, it_end = params.end(); it != it_end; ++it)
|
||||
cmdparams += " " + *it;
|
||||
@@ -56,8 +58,8 @@ class CommandCSSASet : public Command
|
||||
}
|
||||
else
|
||||
{
|
||||
u->SendMessage(ChanServ, NICK_SET_UNKNOWN_OPTION, params[1].c_str());
|
||||
u->SendMessage(ChanServ, MORE_INFO, Config->s_ChanServ.c_str(), "SET");
|
||||
source.Reply(NICK_SET_UNKNOWN_OPTION, params[1].c_str());
|
||||
source.Reply(MORE_INFO, Config->s_ChanServ.c_str(), "SET");
|
||||
}
|
||||
|
||||
return MOD_CONT;
|
||||
|
||||
Reference in New Issue
Block a user