]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_spy.cpp
Change /CHECK <#channel> to correctly report timestamp since it might have been TS...
[user/henk/code/inspircd.git] / src / modules / m_spy.cpp
index e44deb93ba08d6d3b8c3c02855a164ec08f5f3fc..cc8a08674a00ada3171dc838796e29b28c7eec86 100644 (file)
@@ -2,7 +2,7 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2007 InspIRCd Development Team
+ *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
  * See: http://www.inspircd.org/wiki/index.php/Credits
  *
  * This program is free but copyrighted software; see
@@ -14,7 +14,6 @@
 /* $ModDesc: Provides the ability to see the complete names list of channels an oper is not a member of */
 
 #include "inspircd.h"
-#include "wildcard.h"
 
 class ModuleSpy : public Module
 {
@@ -26,27 +25,27 @@ class ModuleSpy : public Module
 
        virtual int OnUserList(User* user, Channel* Ptr, CUList* &nameslist)
        {
-               /* User is an oper and is NOT on the channel */
-               if (IS_OPER(user) && !Ptr->HasUser(user))
+               /* User has priv and is NOT on the channel */
+               if (user->HasPrivPermission("channels/auspex") && !Ptr->HasUser(user))
                        return -1;
 
                return 0;
        }
 
-       void Prioritize()       
-       {                      
+       void Prioritize()
+       {
                /* To ensure that we get priority over namesx and delayjoin for names list generation */
                Module* list[] = { ServerInstance->Modules->Find("m_namesx.so"), ServerInstance->Modules->Find("m_delayjoin.so") };
                ServerInstance->Modules->SetPriority(this, I_OnUserList, PRIO_BEFORE, list, 2);
        }
-       
+
        virtual ~ModuleSpy()
        {
        }
-       
+
        virtual Version GetVersion()
        {
-               return Version(1, 1, 0, 0, VF_VENDOR, API_VERSION);
+               return Version("$Id$", VF_VENDOR, API_VERSION);
        }
 };