summaryrefslogtreecommitdiffstats
path: root/gui
diff options
context:
space:
mode:
Diffstat (limited to 'gui')
-rw-r--r--gui/mainwindow.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp
index 75996c5d..7d1e1510 100644
--- a/gui/mainwindow.cpp
+++ b/gui/mainwindow.cpp
@@ -492,7 +492,10 @@ void MainWindow::doLogin(const QString& errorMsg)
}
else
{
- m_activeLogin = {loginDlg->getUsername(), QString("Offline"), qint64(-1)};
+ QString user = loginDlg->getUsername();
+ if (user.length() == 0)
+ user = QString("Offline");
+ m_activeLogin = {user, QString("Offline"), qint64(-1)};
m_activeInst = m_selectedInstance;
launchInstance(m_activeInst, m_activeLogin);
}