]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_timedbans.cpp
m_callerid Route ACCEPT to the server of the target user only, do not send METADATA...
[user/henk/code/inspircd.git] / src / modules / m_timedbans.cpp
index a3ee9b525e33941ab651290fd183f4419da190bf..a76d89c827d0efc5bf36cdad4001fb82162e8832 100644 (file)
@@ -70,7 +70,7 @@ class CommandTban : public Command
                unsigned long expire = duration + ServerInstance->Time();
                if (duration < 1)
                {
-                       user->WriteServ("NOTICE "+user->nick+" :Invalid ban time");
+                       user->WriteNotice("Invalid ban time");
                        return CMD_FAILURE;
                }
                std::string mask = parameters[2];
@@ -87,7 +87,7 @@ class CommandTban : public Command
                ServerInstance->Parser->CallHandler("MODE",setban,user);
                if (ServerInstance->Modes->GetLastParse().empty())
                {
-                       user->WriteServ("NOTICE "+user->nick+" :Invalid ban mask");
+                       user->WriteNotice("Invalid ban mask");
                        return CMD_FAILURE;
                }
 
@@ -115,11 +115,11 @@ class BanWatcher : public ModeWatcher
 {
  public:
        BanWatcher(Module* parent)
-               : ModeWatcher(parent, 'b', MODETYPE_CHANNEL)
+               : ModeWatcher(parent, "ban", MODETYPE_CHANNEL)
        {
        }
 
-       void AfterMode(User* source, User* dest, Channel* chan, const std::string& banmask, bool adding, ModeType type)
+       void AfterMode(User* source, User* dest, Channel* chan, const std::string& banmask, bool adding)
        {
                if (adding)
                        return;
@@ -151,7 +151,7 @@ class ModuleTimedBans : public Module
        {
        }
 
-       void init()
+       void init() CXX11_OVERRIDE
        {
                ServerInstance->Modules->AddService(cmd);
                Implementation eventlist[] = { I_OnBackgroundTimer };
@@ -164,7 +164,7 @@ class ModuleTimedBans : public Module
                ServerInstance->Modes->DelModeWatcher(&banwatcher);
        }
 
-       virtual void OnBackgroundTimer(time_t curtime)
+       void OnBackgroundTimer(time_t curtime) CXX11_OVERRIDE
        {
                timedbans expired;
                for (timedbans::iterator i = TimedBanList.begin(); i != TimedBanList.end();)
@@ -200,7 +200,7 @@ class ModuleTimedBans : public Module
                }
        }
 
-       virtual Version GetVersion()
+       Version GetVersion() CXX11_OVERRIDE
        {
                return Version("Adds timed bans", VF_COMMON | VF_VENDOR);
        }