diff options
author | Adam <Adam@anope.org> | 2010-08-27 20:56:28 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2010-08-27 20:56:28 -0400 |
commit | c2ddecc2b1dbc9d055166bdf296da2e4536f74f6 (patch) | |
tree | 9b98582630a2debab628e23d4d796885f50ada74 /modules/core/cs_drop.cpp | |
parent | 73fb94c55344b6ad788c925bf13325236402891f (diff) |
Added a new logging system
Diffstat (limited to 'modules/core/cs_drop.cpp')
-rw-r--r-- | modules/core/cs_drop.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/modules/core/cs_drop.cpp b/modules/core/cs_drop.cpp index 608fe3664..4ac066927 100644 --- a/modules/core/cs_drop.cpp +++ b/modules/core/cs_drop.cpp @@ -53,8 +53,6 @@ class CommandCSDrop : public Command return MOD_CONT; } - int level = get_access(u, ci); - if (ci->c && ModeManager::FindChannelModeByName(CMODE_REGISTERED)) ci->c->RemoveMode(NULL, CMODE_REGISTERED, "", false); @@ -64,16 +62,13 @@ class CommandCSDrop : public Command ircdproto->SendSQLineDel(&x); } - Alog() << Config->s_ChanServ << ": Channel " << ci->name << " dropped by " << u->GetMask() << " (founder: " << (ci->founder ? ci->founder->display : "(none)") << ")"; + bool override = (ci->HasFlag(CI_SECUREFOUNDER) ? !IsFounder(u, ci) : !check_access(u, ci, CA_FOUNDER)); + Log(override ? LOG_OVERRIDE : LOG_COMMAND, u, this, ci) << "founder: " << (ci->founder ? ci->founder->display : "none"); + if (override) + ircdproto->SendGlobops(ChanServ, "\2%s\2 used DROP on channel \2%s\2", u->nick.c_str(), ci->name.c_str()); delete ci; - /* We must make sure that the Services admin has not normally the right to - * drop the channel before issuing the wallops. - */ - if (Config->WallDrop && (level < ACCESS_FOUNDER || (!IsFounder(u, ci) && ci->HasFlag(CI_SECUREFOUNDER)))) - ircdproto->SendGlobops(ChanServ, "\2%s\2 used DROP on channel \2%s\2", u->nick.c_str(), chan.c_str()); - notice_lang(Config->s_ChanServ, u, CHAN_DROPPED, chan.c_str()); FOREACH_MOD(I_OnChanDrop, OnChanDrop(chan)); |