diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-03-18 09:42:19 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-03-18 09:42:19 +0000 |
commit | 2a89cef98abad60bf6e6022b81402fdec11f3d5a (patch) | |
tree | 9b7ac7a9ad1e879fd0aedc962d0fb4a89424a260 /src | |
parent | 495ea4be05859f46cbf99c10541210fa3590f01a (diff) |
fix for bug #777
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11228 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r-- | src/modules/m_timedbans.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/modules/m_timedbans.cpp b/src/modules/m_timedbans.cpp index 898fe720e..07a5d8c99 100644 --- a/src/modules/m_timedbans.cpp +++ b/src/modules/m_timedbans.cpp @@ -91,8 +91,12 @@ class CommandTban : public Command T.expire = expire; TimedBanList.push_back(T); channel->WriteAllExcept(user, true, '@', tmp, "NOTICE %s :%s added a timed ban on %s lasting for %ld seconds.", channel->name.c_str(), user->nick.c_str(), mask.c_str(), duration); + ServerInstance->PI->SendChannelNotice(channel, '@', user->nick + " added a timed ban on " + mask + " lasting for " + ConvToStr(duration) + " seconds."); if (ServerInstance->Config->AllowHalfop) + { channel->WriteAllExcept(user, true, '%', tmp, "NOTICE %s :%s added a timed ban on %s lasting for %ld seconds.", channel->name.c_str(), user->nick.c_str(), mask.c_str(), duration); + ServerInstance->PI->SendChannelNotice(channel, '%', user->nick + " added a timed ban on " + mask + " lasting for " + ConvToStr(duration) + " seconds."); + } return CMD_SUCCESS; } return CMD_FAILURE; @@ -165,8 +169,12 @@ class ModuleTimedBans : public Module CUList empty; cr->WriteAllExcept(ServerInstance->FakeClient, true, '@', empty, "NOTICE %s :*** Timed ban on %s expired.", cr->name.c_str(), safei->mask.c_str()); + ServerInstance->PI->SendChannelNotice(cr, '@', "*** Timed ban on " + safei->mask + " expired."); if (ServerInstance->Config->AllowHalfop) + { cr->WriteAllExcept(ServerInstance->FakeClient, true, '%', empty, "NOTICE %s :*** Timed ban on %s expired.", cr->name.c_str(), safei->mask.c_str()); + ServerInstance->PI->SendChannelNotice(cr, '%', "*** Timed ban on " + safei->mask + " expired."); + } /* Removes the ban item for us, no ::erase() needed */ ServerInstance->PI->SendModeStr(safei->channel, std::string("-b ") + setban[2]); |