]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_inviteexception.cpp
Check for windows drive letters on the start of paths and treat them the same as...
[user/henk/code/inspircd.git] / src / modules / m_inviteexception.cpp
index a38f7ed8aa240a62f3e0c598a7e9c56f085d5766..95f27ee0d18d095f77f12900a9fc74344a4aaf96 100644 (file)
@@ -2,7 +2,7 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2007 InspIRCd Development Team
+ *  InspIRCd: (C) 2002-2008 InspIRCd Development Team
  * See: http://www.inspircd.org/wiki/index.php/Credits
  *
  * This program is free but copyrighted software; see
@@ -34,7 +34,7 @@ class InspIRCd* ServerInstance;
 class InviteException : public ListModeBase
 {
  public:
-       InviteException(InspIRCd* Instance) : ListModeBase(Instance, 'I', "End of Channel Invite Exception List", "346", "347", true) { }
+       InviteException(InspIRCd* Instance) : ListModeBase(Instance, 'I', "End of Channel Invite Exception List", 346, 347, true) { }
 };
 
 class ModuleInviteException : public Module
@@ -44,18 +44,14 @@ public:
        ModuleInviteException(InspIRCd* Me) : Module(Me)
        {
                ie = new InviteException(ServerInstance);
-               if (!ServerInstance->AddMode(ie))
+               if (!ServerInstance->Modes->AddMode(ie))
                        throw ModuleException("Could not add new modes!");
                ServerInstance->Modules->PublishInterface("ChannelBanList", this);
+
+               ie->DoImplements(this);
                Implementation eventlist[] = { I_OnRequest, I_On005Numeric, I_OnCheckInvite };
                ServerInstance->Modules->Attach(eventlist, this, 3);
        }
-
-       virtual void Implements(char* List)
-       {
-               ie->DoImplements(List);
-               List[I_OnRequest] = List[I_On005Numeric] = List[I_OnCheckInvite] = 1;
-       }
        
        virtual void On005Numeric(std::string &output)
        {
@@ -87,7 +83,7 @@ public:
                return 0;               
        }
 
-       virtual char* OnRequest(Request* request)
+       virtual const char* OnRequest(Request* request)
        {
                ListModeRequest* LM = (ListModeRequest*)request;
                if (strcmp("LM_CHECKLIST", request->GetId()) == 0)
@@ -134,7 +130,7 @@ public:
                
        virtual Version GetVersion()
        {
-               return Version(1, 1, 0, 3, VF_VENDOR | VF_COMMON, API_VERSION);
+               return Version(1, 2, 0, 3, VF_VENDOR | VF_COMMON, API_VERSION);
        }
 
        ~ModuleInviteException()