]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_banexception.cpp
Fix various warnings when building with LLVM 3.5.
[user/henk/code/inspircd.git] / src / modules / m_banexception.cpp
index 14908fafc19e01d0030c146927aeb15da7e6f296..1811f743de59e5dd7fc64124b1d66ba5ccb9cb32 100644 (file)
@@ -52,13 +52,15 @@ class ModuleBanException : public Module
 public:
        ModuleBanException() : be(this)
        {
-               if (!ServerInstance->Modes->AddMode(&be))
-                       throw ModuleException("Could not add new modes!");
+       }
+
+       void init()
+       {
+               ServerInstance->Modules->AddService(be);
 
                be.DoImplements(this);
                Implementation list[] = { I_OnRehash, I_On005Numeric, I_OnExtBanCheck, I_OnCheckChannelBan };
-               ServerInstance->Modules->Attach(list, this, 4);
-
+               ServerInstance->Modules->Attach(list, this, sizeof(list)/sizeof(Implementation));
        }
 
        void On005Numeric(std::string &output)