X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_kicknorejoin.cpp;h=16def4d7986f1cb291e59c380c85a106596d3bcf;hb=8e89fe75f9467969bce1dc6930befc6ef273edf6;hp=2cb8668d20da167ea5e5c557a6e8a5a7e6f2afe8;hpb=12b9855339a3bbd05cc0636588ea68bf8db390f5;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_kicknorejoin.cpp b/src/modules/m_kicknorejoin.cpp index 2cb8668d2..16def4d79 100644 --- a/src/modules/m_kicknorejoin.cpp +++ b/src/modules/m_kicknorejoin.cpp @@ -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 @@ -46,7 +46,7 @@ class KickRejoin : public ModeHandler return (their_param < our_param); } - ModeAction OnModeChange(User* source, User* dest, Channel* channel, std::string ¶meter, bool adding) + ModeAction OnModeChange(User* source, User* dest, Channel* channel, std::string ¶meter, bool adding, bool) { if (!adding) { @@ -124,13 +124,13 @@ public: { kr = new KickRejoin(ServerInstance); - if (!ServerInstance->AddMode(kr)) + if (!ServerInstance->Modes->AddMode(kr)) throw ModuleException("Could not add new modes!"); Implementation eventlist[] = { I_OnCleanup, I_OnChannelDelete, I_OnUserPreJoin, I_OnUserKick }; ServerInstance->Modules->Attach(eventlist, this, 4); } - virtual int OnUserPreJoin(User* user, Channel* chan, const char* cname, std::string &privs) + virtual int OnUserPreJoin(User* user, Channel* chan, const char* cname, std::string &privs, const std::string &keygiven) { if (chan) { @@ -201,10 +201,6 @@ public: OnChannelDelete((Channel*)item); } - virtual void Implements(char* List) - { - List[I_OnCleanup] = List[I_OnChannelDelete] = List[I_OnUserPreJoin] = List[I_OnUserKick] = 1; - } virtual ~ModuleKickNoRejoin() { @@ -214,7 +210,7 @@ public: virtual Version GetVersion() { - return Version(1, 1, 0, 0, VF_COMMON | VF_VENDOR, API_VERSION); + return Version(1, 2, 0, 0, VF_COMMON | VF_VENDOR, API_VERSION); } };