From 91876870c8e20af8c51ba4230577de3313149c39 Mon Sep 17 00:00:00 2001 From: brain Date: Sun, 4 Nov 2007 16:32:18 +0000 Subject: For now, just fix the Priority Prioritize(). We might be able to do the rest with a perl script git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8503 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_banredirect.cpp | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'src/modules') diff --git a/src/modules/m_banredirect.cpp b/src/modules/m_banredirect.cpp index 60bd1bba4..4a7db8052 100644 --- a/src/modules/m_banredirect.cpp +++ b/src/modules/m_banredirect.cpp @@ -197,11 +197,9 @@ class ModuleBanRedirect : public Module throw ModuleException("Could not add mode watcher"); OnRehash(NULL, ""); - } - - void Implements(char* List) - { - List[I_OnRehash] = List[I_OnUserPreJoin] = List[I_OnChannelDelete] = List[I_OnCleanup] = 1; + + Implementation list[] = { I_OnRehash, I_OnUserPreJoin, I_OnChannelDelete, I_OnCleanup }; + Me->Modules->Attach(list, this, sizeof(list)); } virtual void OnChannelDelete(Channel* chan) @@ -327,11 +325,11 @@ class ModuleBanRedirect : public Module return Version(1, 0, 0, 0, VF_COMMON | VF_VENDOR, API_VERSION); } - Priority Prioritize() + void Prioritize() { - return (Priority)ServerInstance->Modules->PriorityBefore("m_banexception.so"); + Module* banex = ServerInstance->Modules->Find("m_banexception.so"); + ServerInstance->Modules->SetPriority(this, I_OnUserPreJoin, PRIO_BEFORE, &banex); } }; - MODULE_INIT(ModuleBanRedirect) -- cgit v1.2.3