diff options
author | Adam <Adam@anope.org> | 2013-09-27 11:03:11 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2013-09-27 19:11:02 -0400 |
commit | 17196887ad1e6f9886c6cd3109bd8ede16ae7343 (patch) | |
tree | 970fdc1b83df474ee71fb3227a7c1c4fba1c53c2 /modules/commands/cs_mode.cpp | |
parent | 02d67f682a0f507575369df99ab80024f5e3d7ce (diff) |
Allow modifying mlock on nonexistant (but registered) channels
Diffstat (limited to 'modules/commands/cs_mode.cpp')
-rw-r--r-- | modules/commands/cs_mode.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/modules/commands/cs_mode.cpp b/modules/commands/cs_mode.cpp index 69644748f..2eec98f17 100644 --- a/modules/commands/cs_mode.cpp +++ b/modules/commands/cs_mode.cpp @@ -671,8 +671,8 @@ class CommandCSMode : public Command ChannelInfo *ci = ChannelInfo::Find(params[0]); - if (!ci || !ci->c) - source.Reply(CHAN_X_NOT_IN_USE, params[0].c_str()); + if (!ci) + source.Reply(CHAN_X_NOT_REGISTERED, params[0].c_str()); else if (subcommand.equals_ci("LOCK") && params.size() > 2) { if (!source.AccessFor(ci).HasPriv("MODE") && !source.HasPriv("chanserv/administration")) @@ -680,6 +680,8 @@ class CommandCSMode : public Command else this->DoLock(source, ci, params); } + else if (!ci->c) + source.Reply(CHAN_X_NOT_IN_USE, params[0].c_str()); else if (subcommand.equals_ci("SET") && params.size() > 2) this->DoSet(source, ci, params); else if (subcommand.equals_ci("CLEAR")) |