diff --git a/backends/libcommuni/singleircnetworkplugin.cpp b/backends/libcommuni/singleircnetworkplugin.cpp index f668e5438b7f498025e6cf63df360af037c086b5..af44ccfac5e31814267a3fb7c6343b1ff237d790 100644 --- a/backends/libcommuni/singleircnetworkplugin.cpp +++ b/backends/libcommuni/singleircnetworkplugin.cpp @@ -50,10 +50,12 @@ void SingleIRCNetworkPlugin::handleLoginRequest(const std::string &user, const s session->setHost(QString::fromStdString(m_server)); session->setPort(6667); - std::string identify = m_identify; - boost::replace_all(identify, "$password", password); - boost::replace_all(identify, "$name", legacyName); - session->setIdentify(identify); + if (!password.empty()) { + std::string identify = m_identify; + boost::replace_all(identify, "$password", password); + boost::replace_all(identify, "$name", legacyName); + session->setIdentify(identify); + } session->open();