mirror of
https://github.com/MultiMC/MultiMC5.git
synced 2024-11-20 08:10:11 +00:00
Bugfixes for auto login
This commit is contained in:
parent
003fedde01
commit
867efd53a2
@ -461,14 +461,15 @@ void MainWindow::on_actionLaunchInstance_triggered()
|
||||
{
|
||||
if (m_selectedInstance)
|
||||
{
|
||||
bool autoLogin = MMC->settings()->get("AutoLogin").toBool();
|
||||
if(autoLogin) doAutoLogin();
|
||||
else doLogin();
|
||||
doLogin();
|
||||
}
|
||||
}
|
||||
|
||||
void MainWindow::doAutoLogin()
|
||||
{
|
||||
if (!m_selectedInstance)
|
||||
return;
|
||||
|
||||
Keyring * k = Keyring::instance();
|
||||
QStringList accounts = k->getStoredAccounts("minecraft");
|
||||
|
||||
@ -480,6 +481,7 @@ void MainWindow::doAutoLogin()
|
||||
if(!password.isEmpty())
|
||||
{
|
||||
QLOG_INFO() << "Automatically logging in with stored account: " << username;
|
||||
m_activeInst = m_selectedInstance;
|
||||
doLogin(username, password);
|
||||
}
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user