aboutsummaryrefslogtreecommitdiffstats
path: root/src/users.cpp
diff options
context:
space:
mode:
authorGravatar Attila Molnar2016-03-30 12:30:26 +0200
committerGravatar Attila Molnar2016-03-30 12:30:26 +0200
commit3c725be2833f77d7850dbb2c8cdc6be64d95c0ab (patch)
treecd093c6b3a2d31474874eb95e0940e25ca9a53e4 /src/users.cpp
parentMerge branch 'master+stroute' (diff)
parentMake User::WriteRemoteNumeric() virtual, implement it in SpanningTree::Remote... (diff)
downloadinspircd++-3c725be2833f77d7850dbb2c8cdc6be64d95c0ab.tar.gz
inspircd++-3c725be2833f77d7850dbb2c8cdc6be64d95c0ab.tar.bz2
inspircd++-3c725be2833f77d7850dbb2c8cdc6be64d95c0ab.zip
Merge branch 'master+stnum'
Diffstat (limited to 'src/users.cpp')
-rw-r--r--src/users.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/users.cpp b/src/users.cpp
index 12fb902fb..7437e8a20 100644
--- a/src/users.cpp
+++ b/src/users.cpp
@@ -811,7 +811,8 @@ void User::WriteNumeric(const Numeric::Numeric& numeric)
if (MOD_RESULT == MOD_RES_DENY)
return;
- this->Write(BuildNumeric(ServerInstance->Config->ServerName, this, numeric.GetNumeric(), numeric.GetParams()));
+ const std::string& servername = (numeric.GetServer() ? numeric.GetServer()->GetName() : ServerInstance->Config->ServerName);
+ this->Write(BuildNumeric(servername, this, numeric.GetNumeric(), numeric.GetParams()));
}
void User::WriteFrom(User *user, const std::string &text)
@@ -949,8 +950,7 @@ void User::SendText(const char *text, ...)
void User::WriteRemoteNumeric(const Numeric::Numeric& numeric)
{
- const std::string& servername = (numeric.GetServer() ? numeric.GetServer()->GetName() : ServerInstance->Config->ServerName);
- SendText(BuildNumeric(servername, this, numeric.GetNumeric(), numeric.GetParams()));
+ WriteNumeric(numeric);
}
/* return 0 or 1 depending if users u and u2 share one or more common channels