Commit 6fa548a1 authored by louiz’'s avatar louiz’

Display all the MODE arguments in the message

parent a4c845ab
......@@ -377,10 +377,18 @@ void IrcClient::on_channel_mode(const IrcMessage& message)
iid.chan = message.arguments[0];
iid.server = this->hostname;
IrcUser user(message.prefix);
std::string mode_arguments;
for (size_t i = 1; i < message.arguments.size(); ++i)
{
if (!message.arguments[i].empty())
{
if (i != 1)
mode_arguments += " ";
mode_arguments += message.arguments[i];
}
}
this->bridge->send_message(iid, "", std::string("Mode ") + iid.chan +
" [" + message.arguments[1] +
(message.arguments.size() > 2 ? (" " + message.arguments[2]): "")
+ "] by " + user.nick,
" [" + mode_arguments + "] by " + user.nick,
true);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment