From 73573ebb2abb2aea119a6c99e2bf4a302f2ba834 Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Sun, 6 Sep 2015 18:57:35 +0200 Subject: Trivial cleanup in irc_client.cpp --- src/irc/irc_client.cpp | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'src/irc/irc_client.cpp') diff --git a/src/irc/irc_client.cpp b/src/irc/irc_client.cpp index 6ab19b7..29f0b54 100644 --- a/src/irc/irc_client.cpp +++ b/src/irc/irc_client.cpp @@ -492,9 +492,8 @@ void IrcClient::on_rpl_listend(const IrcMessage&) { } -void IrcClient::empty_motd(const IrcMessage& message) +void IrcClient::empty_motd(const IrcMessage&) { - (void)message; this->motd.erase(); } @@ -507,16 +506,13 @@ void IrcClient::on_motd_line(const IrcMessage& message) this->motd += body+"\n"; } -void IrcClient::send_motd(const IrcMessage& message) +void IrcClient::send_motd(const IrcMessage&) { - (void)message; this->bridge->send_xmpp_message(this->hostname, "", this->motd); } void IrcClient::on_topic_received(const IrcMessage& message) { - if (message.arguments.size() < 2) - return; const std::string chan_name = utils::tolower(message.arguments[message.arguments.size() - 2]); IrcChannel* channel = this->get_channel(chan_name); channel->topic = message.arguments[message.arguments.size() - 1]; @@ -709,9 +705,9 @@ void IrcClient::on_nick(const IrcMessage& message) void IrcClient::on_kick(const IrcMessage& message) { + const std::string chan_name = utils::tolower(message.arguments[0]); const std::string target = message.arguments[1]; const std::string reason = message.arguments[2]; - const std::string chan_name = utils::tolower(message.arguments[0]); IrcChannel* channel = this->get_channel(chan_name); if (!channel->joined) return ; -- cgit v1.2.3