summaryrefslogtreecommitdiff
path: root/src/users.cpp
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2010-02-01 01:18:34 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2010-02-01 01:18:34 +0000
commit53b99c7324b5868e1660feca4dd81988bd43d371 (patch)
treec176ab7ef69bbfb0e8e065f4c8e1bc7d5d0e1781 /src/users.cpp
parentaca3ddf2307fd69c1fe0a396084d1f8ff758af26 (diff)
Don't run OnUserPostNick hook for initial NICK command
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12341 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/users.cpp')
-rw-r--r--src/users.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/users.cpp b/src/users.cpp
index c390e3471..2cc26c158 100644
--- a/src/users.cpp
+++ b/src/users.cpp
@@ -975,7 +975,9 @@ bool User::ChangeNick(const std::string& newnick, bool force)
ServerInstance->Users->clientlist->erase(oldnick);
(*(ServerInstance->Users->clientlist))[newnick] = this;
- FOREACH_MOD(I_OnUserPostNick,OnUserPostNick(this,oldnick));
+ if (registered == REG_ALL)
+ FOREACH_MOD(I_OnUserPostNick,OnUserPostNick(this,oldnick));
+
return true;
}