]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_callerid.cpp
Merge pull request #1139 from johanna-a/master
[user/henk/code/inspircd.git] / src / modules / m_callerid.cpp
index efbf1a81b690609b9277030cde7eb242e42c4a89..c844ef04f45b1cfbceb8b6fe5707fb06bd6cd081 100644 (file)
@@ -69,7 +69,7 @@ class callerid_data
 struct CallerIDExtInfo : public ExtensionItem
 {
        CallerIDExtInfo(Module* parent)
-               : ExtensionItem("callerid_data", parent)
+               : ExtensionItem("callerid_data", ExtensionItem::EXT_USER, parent)
        {
        }
 
@@ -98,7 +98,7 @@ struct CallerIDExtInfo : public ExtensionItem
                while (s.GetToken(tok))
                {
                        User *u = ServerInstance->FindNick(tok);
-                       if ((u) && (u->registered == REG_ALL) && (!u->quitting) && (!IS_SERVER(u)))
+                       if ((u) && (u->registered == REG_ALL) && (!u->quitting))
                        {
                                if (dat->accepting.insert(u).second)
                                {
@@ -170,7 +170,7 @@ class CommandAccept : public Command
                else
                        target = ServerInstance->FindNickOnly(tok);
 
-               if ((!target) || (target->registered != REG_ALL) || (target->quitting) || (IS_SERVER(target)))
+               if ((!target) || (target->registered != REG_ALL) || (target->quitting))
                        target = NULL;
 
                return std::make_pair(target, !remove);
@@ -426,6 +426,12 @@ public:
                tracknick = tag->getBool("tracknick");
                notify_cooldown = tag->getInt("cooldown", 60);
        }
+
+       void Prioritize() CXX11_OVERRIDE
+       {
+               // Want to be after modules like silence or services_account
+               ServerInstance->Modules->SetPriority(this, I_OnUserPreMessage, PRIORITY_LAST);
+       }
 };
 
 MODULE_INIT(ModuleCallerID)