core: Fix CAP REQ display for SASL only supported
authorShane Synan <digitalcircuit36939@gmail.com>
Tue, 27 Feb 2018 19:50:43 +0000 (13:50 -0600)
committerManuel Nickschas <sputnick@quassel-irc.org>
Thu, 5 Apr 2018 22:04:54 +0000 (00:04 +0200)
commit44f5b91807ce2181d9c151d9e93f12e3f798aa0e
tree9d7f0a5432b429469597e4435872fa33b9c57bba
parent3497660529f9fa912f4d46ca2da9e0c97310076c
core: Fix CAP REQ display for SASL only supported

Modify queuedCapsDisplay to only add a ", " when both
_capsQueuedIndividual and _capsQueuedBundled are not empty.  This
avoids adding a spurious ", " when there's only individual caps, e.g.
SASL.  Though the docs don't mention it, QStringList.join() will only
add the separator when there's more than one item in the list.

Before:
* Negotiating capabilities (requesting: sasl, )...
After:
* Negotiating capabilities (requesting: sasl)...

See https://doc.qt.io/qt-5/qstringlist.html#join

Closes GH-334.
src/core/corenetwork.cpp