Ref T401, mapping tool login updates crashpad info

This commit is contained in:
Klaus Basan
2018-11-01 16:58:40 +01:00
parent 66a1b32f0f
commit 4ba14fe9a9
2 changed files with 9 additions and 8 deletions

View File

@@ -17,6 +17,7 @@
#include <QJsonArray>
#include <QJsonValue>
#include <QStringBuilder>
#include <QtGlobal>
namespace BlackMisc
@@ -38,7 +39,7 @@ namespace BlackMisc
{
if (hasValidRealName())
{
return m_realname + " " + getDbKeyAsStringInParentheses();
return m_realname % QStringLiteral(" ") % getDbKeyAsStringInParentheses();
}
else
{
@@ -49,13 +50,8 @@ namespace BlackMisc
QString CAuthenticatedUser::convertToQString(bool i18n) const
{
Q_UNUSED(i18n);
if (m_realname.isEmpty()) return "<no realname>";
QString s = m_realname;
if (this->hasValidDbKey())
{
s.append(this->getDbKeyAsStringInParentheses(" "));
}
return s;
if (m_realname.isEmpty()) { return QStringLiteral("<no realname>"); }
return m_realname % (this->hasValidDbKey() ? this->getDbKeyAsStringInParentheses(" ") : QStringLiteral(""));
}
CAuthenticatedUser CAuthenticatedUser::fromDatabaseJson(const QJsonObject &json)