]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_chanfilter.cpp
Update wiki links to use HTTPS and point to the correct pages.
[user/henk/code/inspircd.git] / src / modules / m_chanfilter.cpp
index 2c89950445a83bc5b5ace04611310d0ea2b816a8..651e659b59d437bfd468573ffc1a676a0d03c7f5 100644 (file)
@@ -80,12 +80,11 @@ class ModuleChanFilter : public Module
 
        void init()
        {
-               if (!ServerInstance->Modes->AddMode(&cf))
-                       throw ModuleException("Could not add new modes!");
+               ServerInstance->Modules->AddService(cf);
 
                cf.DoImplements(this);
                Implementation eventlist[] = { I_OnRehash, I_OnUserPreMessage, I_OnUserPreNotice, I_OnSyncChannel };
-               ServerInstance->Modules->Attach(eventlist, this, 4);
+               ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
 
                OnRehash(NULL);
        }