diff options
-rw-r--r-- | src/gui/application.cpp | 5 | ||||
-rw-r--r-- | src/gui/application.h | 1 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/gui/application.cpp b/src/gui/application.cpp index 24a8a25b9..5ca9d25f7 100644 --- a/src/gui/application.cpp +++ b/src/gui/application.cpp @@ -108,6 +108,7 @@ Application::Application(int &argc, char **argv) , _userTriggeredConnect(false) , _debugMode(false) , _backgroundMode(false) + , _isQuitting(false) { _startedAt.start(); @@ -285,7 +286,7 @@ void Application::slotAccountStateRemoved(AccountState *accountState) } // if there is no more account, show the wizard. - if (AccountManager::instance()->accounts().isEmpty()) { + if (!_isQuitting && AccountManager::instance()->accounts().isEmpty()) { // allow to add a new account if there is non any more. Always think // about single account theming! OwncloudSetupWizard::runWizard(this, SLOT(slotownCloudWizardDone(int))); @@ -308,6 +309,8 @@ void Application::slotAccountStateAdded(AccountState *accountState) void Application::slotCleanup() { + _isQuitting = true; + AccountManager::instance()->save(); FolderMan::instance()->unloadAndDeleteAllFolders(); diff --git a/src/gui/application.h b/src/gui/application.h index 77abd7a97..f0e24548e 100644 --- a/src/gui/application.h +++ b/src/gui/application.h @@ -114,6 +114,7 @@ private: bool _userTriggeredConnect; bool _debugMode; bool _backgroundMode; + bool _isQuitting; ClientProxy _proxy; |