X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fcommon%2Fnetwork.h;h=37bdadbe3b10a77469f0f68f43f195997a50a9f6;hb=899709300734acc2bac01b1d57a1fd8fe2a6d923;hp=addb1d5f42e11e6ff7001317ad8e816bcd848272;hpb=dba66762993507168b1a3de25cfd2d7bff0ff969;p=quassel.git diff --git a/src/common/network.h b/src/common/network.h index addb1d5f..37bdadbe 100644 --- a/src/common/network.h +++ b/src/common/network.h @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2005-2016 by the Quassel Project * + * Copyright (C) 2005-2018 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -180,11 +180,11 @@ public : QString prefixToMode(const QString &prefix) const; inline QString prefixToMode(const QCharRef &prefix) const { return prefixToMode(QString(prefix)); } inline QString prefixesToModes(const QString &prefix) const { - QString mode = ""; + QString modes; for (QChar c : prefix) { - mode += prefixToMode(c); + modes += prefixToMode(c); } - return mode; + return modes; } /**@}*/ @@ -196,11 +196,11 @@ public : QString modeToPrefix(const QString &mode) const; inline QString modeToPrefix(const QCharRef &mode) const { return modeToPrefix(QString(mode)); } inline QString modesToPrefixes(const QString &mode) const { - QString prefix = ""; + QString prefixes; for (QChar c : mode) { - prefix += modeToPrefix(c); + prefixes += modeToPrefix(c); } - return prefix; + return prefixes; } /**@}*/ @@ -295,7 +295,7 @@ public : * * These results aren't valid if the network is disconnected or capability negotiation hasn't * happened, and some servers might not correctly advertise capabilities. Don't treat this as - * a guarentee. + * a guarantee. * * @param[in] capability Name of capability * @returns True if connected and advertised by the server, otherwise false