summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree
diff options
context:
space:
mode:
authorattilamolnar <attilamolnar@hush.com>2012-07-01 22:07:47 +0200
committerattilamolnar <attilamolnar@hush.com>2012-08-08 15:04:17 +0200
commita459f5b0e3e2ed219665feb7d3bc5d00d1643027 (patch)
tree3261444c65148bc7a02b82ef31cfecd6408a8bda /src/modules/m_spanningtree
parent1d7764cbc14a53c4b0222edefae23df5d9b4bdc8 (diff)
m_spanningtree Specify the uuid of the remote user when sending server NOTICE/PRIVMSG to him
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r--src/modules/m_spanningtree/protocolinterface.cpp26
1 files changed, 8 insertions, 18 deletions
diff --git a/src/modules/m_spanningtree/protocolinterface.cpp b/src/modules/m_spanningtree/protocolinterface.cpp
index 9c489fcb4..3ab5dae9d 100644
--- a/src/modules/m_spanningtree/protocolinterface.cpp
+++ b/src/modules/m_spanningtree/protocolinterface.cpp
@@ -164,26 +164,16 @@ void SpanningTreeProtocolInterface::SendChannelNotice(Channel* target, char stat
void SpanningTreeProtocolInterface::SendUserPrivmsg(User* target, const std::string &text)
{
- TreeServer* serv = Utils->FindServer(target->server);
- if (serv)
- {
- TreeSocket* sock = serv->GetSocket();
- if (sock)
- {
- sock->WriteLine(":" + ServerInstance->Config->GetSID() + " PRIVMSG " + target->nick + " :"+text);
- }
- }
+ parameterlist p;
+ p.push_back(target->uuid);
+ p.push_back(":" + text);
+ Utils->DoOneToOne(ServerInstance->Config->GetSID(), "PRIVMSG", p, target->server);
}
void SpanningTreeProtocolInterface::SendUserNotice(User* target, const std::string &text)
{
- TreeServer* serv = Utils->FindServer(target->server);
- if (serv)
- {
- TreeSocket* sock = serv->GetSocket();
- if (sock)
- {
- sock->WriteLine(":" + ServerInstance->Config->GetSID() + " NOTICE " + target->nick + " :"+text);
- }
- }
+ parameterlist p;
+ p.push_back(target->uuid);
+ p.push_back(":" + text);
+ Utils->DoOneToOne(ServerInstance->Config->GetSID(), "NOTICE", p, target->server);
}