]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_halfop.cpp
Switch <stdint.h> test to use a test file too.
[user/henk/code/inspircd.git] / src / modules / m_halfop.cpp
index 2c4b086cb4f3f96f0ff8c76521a45a9de4ad1909..3194fcde8ea29308798cd0e45af3fbcbbb54232c 100644 (file)
@@ -17,6 +17,8 @@
  */
 
 
+/* $ModDesc: Channel half-operator mode provider */
+
 #include "inspircd.h"
 
 class ModeChannelHalfOp : public ModeHandler
@@ -86,13 +88,11 @@ class ModuleHalfop : public Module
  public:
        ModuleHalfop() : mh(this)
        {
-               if (!ServerInstance->Modes->AddMode(&mh))
-                       throw ModuleException("Could not add new modes!");
        }
 
-       ~ModuleHalfop()
+       void init()
        {
-               ServerInstance->Modes->DelMode(&mh);
+               ServerInstance->Modules->AddService(mh);
        }
 
        Version GetVersion()