summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/modules/m_spanningtree/treesocket2.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/modules/m_spanningtree/treesocket2.cpp b/src/modules/m_spanningtree/treesocket2.cpp
index 4736976b3..f8ba67cc5 100644
--- a/src/modules/m_spanningtree/treesocket2.cpp
+++ b/src/modules/m_spanningtree/treesocket2.cpp
@@ -284,18 +284,26 @@ bool TreeSocket::ForceNick(const std::string &prefix, std::deque<std::string> &p
if (u)
{
Utils->DoOneToAllButSender(prefix,"SVSNICK",params,prefix);
+
if (IS_LOCAL(u))
{
std::deque<std::string> par;
par.push_back(params[1]);
+
if (!u->ForceNickChange(params[1].c_str()))
{
- userrec::QuitUser(this->Instance, u, "Nickname collision");
- return true;
+ /* buh. UID them */
+ if (!u->ForceNickChange(u->uuid))
+ {
+ userrec::QuitUser(this->Instance, u, "Nickname collision");
+ return true;
+ }
}
+
u->age = atoi(params[2].c_str());
}
}
+
return true;
}