]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_nonicks.cpp
Allow non-opers to use /MKPASSWD
[user/henk/code/inspircd.git] / src / modules / m_nonicks.cpp
index 9a1d0079e5ba3deca4c511b50d4714246d4b22ce..14957759c6b4c8f5be6ce0a4fbb87ff52bc03164 100644 (file)
@@ -2,7 +2,7 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2008 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
@@ -64,7 +64,7 @@ class ModuleNoNickChange : public Module
 
        virtual Version GetVersion()
        {
-               return Version(1,2,0,1,VF_COMMON|VF_VENDOR,API_VERSION);
+               return Version("$Id$", VF_COMMON | VF_VENDOR, API_VERSION);
        }
 
 
@@ -81,6 +81,10 @@ class ModuleNoNickChange : public Module
                if (isdigit(newnick[0])) /* don't even think about touching a switch to uid! */
                        return 0;
 
+               // Allow forced nick changes.
+               if (user->GetExt("NICKForced"))
+                       return 0;
+
                for (UCListIter i = user->chans.begin(); i != user->chans.end(); i++)
                {
                        Channel* curr = i->first;