Commit f9e259c2 authored by louiz’'s avatar louiz’

Fix a little bit of style stuf from previous commit

parent e4fcbd30
...@@ -58,7 +58,7 @@ public: ...@@ -58,7 +58,7 @@ public:
* Try to join an irc_channel, does nothing and return true if the channel * Try to join an irc_channel, does nothing and return true if the channel
* was already joined. * was already joined.
*/ */
bool join_irc_channel(const Iid& iid, const std::string& username, const std::string& password = ""); bool join_irc_channel(const Iid& iid, const std::string& username, const std::string& password);
void send_channel_message(const Iid& iid, const std::string& body); void send_channel_message(const Iid& iid, const std::string& body);
void send_private_message(const Iid& iid, const std::string& body, const std::string& type="PRIVMSG"); void send_private_message(const Iid& iid, const std::string& body, const std::string& type="PRIVMSG");
void leave_irc_channel(Iid&& iid, std::string&& status_message); void leave_irc_channel(Iid&& iid, std::string&& status_message);
......
...@@ -339,8 +339,9 @@ void XmppComponent::handle_presence(const Stanza& stanza) ...@@ -339,8 +339,9 @@ void XmppComponent::handle_presence(const Stanza& stanza)
if (!own_nick.empty() && own_nick != to.resource) if (!own_nick.empty() && own_nick != to.resource)
bridge->send_irc_nick_change(iid, to.resource); bridge->send_irc_nick_change(iid, to.resource);
XmlNode* x = stanza.get_child("x", MUC_NS); XmlNode* x = stanza.get_child("x", MUC_NS);
XmlNode* password = x? x->get_child("password", MUC_NS): NULL; XmlNode* password = x ? x->get_child("password", MUC_NS): nullptr;
bridge->join_irc_channel(iid, to.resource, password? password->get_inner(): ""); bridge->join_irc_channel(iid, to.resource,
password ? password->get_inner() : "");
} }
else if (type == "unavailable") else if (type == "unavailable")
{ {
......
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