summaryrefslogtreecommitdiff
path: root/modules/pseudoclients/botserv.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2013-01-08 20:25:01 -0500
committerAdam <Adam@anope.org>2013-01-08 20:25:01 -0500
commit9931ec299446c3d9e149f91a953748350c38eba6 (patch)
treefb3969d5aeb2ce23a7d2cde9fd9e47841b125c4b /modules/pseudoclients/botserv.cpp
parent5f3dfc296041540960f372b010eea623bdd7d335 (diff)
Use m_rewrite to rewrite op, deop, halfop, ... etc
Diffstat (limited to 'modules/pseudoclients/botserv.cpp')
-rw-r--r--modules/pseudoclients/botserv.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/pseudoclients/botserv.cpp b/modules/pseudoclients/botserv.cpp
index 3d4bf33f2..3716c3bc3 100644
--- a/modules/pseudoclients/botserv.cpp
+++ b/modules/pseudoclients/botserv.cpp
@@ -108,9 +108,9 @@ class BotServCore : public Module
for (unsigned i = 0, j = params.size() - (count - 1); i < j; ++i)
params.erase(params.begin());
- /* All ChanServ commands take the channel as a first parameter */
- if (cmd->name.find("chanserv/") == 0 && !cmd->HasFlag(CFLAG_STRIP_CHANNEL))
- params.insert(params.begin(), c->ci->name);
+ /* Some commands take the channel as a first parameter */
+ if (info.prepend_channel)
+ params.insert(params.begin(), c->name);
while (cmd->max_params > 0 && params.size() > cmd->max_params)
{