summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r--src/modules/m_spanningtree/treesocket2.cpp17
1 files changed, 10 insertions, 7 deletions
diff --git a/src/modules/m_spanningtree/treesocket2.cpp b/src/modules/m_spanningtree/treesocket2.cpp
index aeb63c99c..364586dff 100644
--- a/src/modules/m_spanningtree/treesocket2.cpp
+++ b/src/modules/m_spanningtree/treesocket2.cpp
@@ -377,21 +377,24 @@ void TreeSocket::ProcessConnectedLine(std::string& taglist, std::string& prefix,
CmdResult res;
ClientProtocol::TagMap tags;
+ std::string tag;
+ irc::sepstream tagstream(taglist, ';');
+ while (tagstream.GetToken(tag))
+ ProcessTag(who, tag, tags);
+
+ CommandBase::Params newparams(params, tags);
+
if (scmd)
- res = scmd->Handle(who, params);
+ res = scmd->Handle(who, newparams);
else
{
- std::string tag;
- irc::sepstream tagstream(taglist, ';');
- while (tagstream.GetToken(tag))
- ProcessTag(who, tag, tags);
- res = cmd->Handle(who, CommandBase::Params(params, tags));
+ res = cmd->Handle(who, newparams);
if (res == CMD_INVALID)
throw ProtocolException("Error in command handler");
}
if (res == CMD_SUCCESS)
- Utils->RouteCommand(server->GetRoute(), cmdbase, CommandBase::Params(params, tags), who);
+ Utils->RouteCommand(server->GetRoute(), cmdbase, newparams, who);
}
void TreeSocket::OnTimeout()