summaryrefslogtreecommitdiff
path: root/modules/pseudoclients/chanserv.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2013-01-21 22:31:16 -0500
committerAdam <Adam@anope.org>2013-01-21 22:31:16 -0500
commitddaa001dafb5122e6e363e4acbbe6ce045b7b104 (patch)
tree0364a76606ac6e2881ebd663601ce260f7c1101e /modules/pseudoclients/chanserv.cpp
parent51c049e1a738e9124bab3961f35b830906517421 (diff)
Merge usefulness of Flags and Extensible classes into Extensible, made most flags we have juse strings instead of defines/enums
Diffstat (limited to 'modules/pseudoclients/chanserv.cpp')
-rw-r--r--modules/pseudoclients/chanserv.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/pseudoclients/chanserv.cpp b/modules/pseudoclients/chanserv.cpp
index 0beb610ee..ee8c08ed6 100644
--- a/modules/pseudoclients/chanserv.cpp
+++ b/modules/pseudoclients/chanserv.cpp
@@ -43,7 +43,7 @@ class ExpireCallback : public CallBack
expire = true;
}
- if (ci->HasFlag(CI_NO_EXPIRE))
+ if (ci->HasExt("NO_EXPIRE"))
expire = false;
FOREACH_MOD(I_OnPreChanExpire, OnPreChanExpire(ci, expire));
@@ -51,7 +51,7 @@ class ExpireCallback : public CallBack
if (expire)
{
Anope::string extra;
- if (ci->HasFlag(CI_SUSPENDED))
+ if (ci->HasExt("SUSPENDED"))
extra = "suspended ";
Log(LOG_NORMAL, "chanserv/expire") << "Expiring " << extra << "channel " << ci->name << " (founder: " << (ci->GetFounder() ? ci->GetFounder()->display : "(none)") << ")";
@@ -92,7 +92,7 @@ class ChanServCore : public Module
EventReturn OnBotPrivmsg(User *u, BotInfo *bi, Anope::string &message) anope_override
{
- if (Config->CSOpersOnly && !u->HasMode(UMODE_OPER) && bi->nick == Config->ChanServ)
+ if (Config->CSOpersOnly && bi == ChanServ && !u->HasMode("OPER"))
{
u->SendMessage(bi, ACCESS_DENIED);
return EVENT_STOP;
@@ -164,7 +164,7 @@ class ChanServCore : public Module
for (unsigned j = ci->GetAkickCount(); j > 0; --j)
{
const AutoKick *akick = ci->GetAkick(j - 1);
- if (akick->HasFlag(AK_ISNICK) && akick->nc == nc)
+ if (akick->nc == nc)
ci->EraseAkick(j - 1);
}
}