]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_botmode.cpp
m_dccallow Add config option to control max entries on a list
[user/henk/code/inspircd.git] / src / modules / m_botmode.cpp
index 3e7fd2fc659e5e3b377a6c165745e639c4237ab3..b29c58240689be37d9e86a4d8be12193c860ef11 100644 (file)
@@ -42,10 +42,9 @@ class ModuleBotMode : public Module
 
        void init()
        {
-               if (!ServerInstance->Modes->AddMode(&bm))
-                       throw ModuleException("Could not add new modes!");
+               ServerInstance->Modules->AddService(bm);
                Implementation eventlist[] = { I_OnWhois };
-               ServerInstance->Modules->Attach(eventlist, this, 1);
+               ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
        }
 
        virtual ~ModuleBotMode()