]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_nickflood.cpp
m_cloaking: fix host/ip comparisons #1249
[user/henk/code/inspircd.git] / src / modules / m_nickflood.cpp
index 349bf1a5d1f38e07f6a2ee2577a7301502e1d26d..04d7c8b5e2cc86d28e812cf578bcc4a64639f282 100644 (file)
@@ -143,9 +143,8 @@ class ModuleNickFlood : public Module
 
        void init()
        {
-               if (!ServerInstance->Modes->AddMode(&nf))
-                       throw ModuleException("Could not add new modes!");
-               ServerInstance->Extensions.Register(&nf.ext);
+               ServerInstance->Modules->AddService(nf);
+               ServerInstance->Modules->AddService(nf.ext);
                Implementation eventlist[] = { I_OnUserPreNick, I_OnUserPostNick };
                ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
        }