diff --git a/src/gui/application.cpp b/src/gui/application.cpp index 995def590b..cebf1c832d 100644 --- a/src/gui/application.cpp +++ b/src/gui/application.cpp @@ -480,11 +480,11 @@ Application::~Application() void Application::setupAccountsAndFolders() { _folderManager.reset(new FolderMan); - FolderMan::instance()->setSyncEnabled(true); const auto accountsRestoreResult = restoreLegacyAccount(); const auto foldersListSize = FolderMan::instance()->setupFolders(); + FolderMan::instance()->setSyncEnabled(true); const auto prettyNamesList = [](const QList &accounts) { QStringList list; diff --git a/src/gui/folderman.cpp b/src/gui/folderman.cpp index ce4c25e7b6..07715a71d7 100644 --- a/src/gui/folderman.cpp +++ b/src/gui/folderman.cpp @@ -604,6 +604,9 @@ void FolderMan::setupLegacyFolder(const QString &fileNamePath, AccountState *acc settings.beginGroup(settingsFoldersWithPlaceholdersC); migrateFoldersGroup(settingsFoldersWithPlaceholdersC); +#ifdef Q_OS_WIN + _navigationPaneHelper.scheduleUpdateCloudStorageRegistry(); +#endif settings.endGroup(); settings.beginGroup(settingsFoldersC); diff --git a/src/gui/navigationpanehelper.cpp b/src/gui/navigationpanehelper.cpp index 578f710227..2f22a387f1 100644 --- a/src/gui/navigationpanehelper.cpp +++ b/src/gui/navigationpanehelper.cpp @@ -66,11 +66,12 @@ void NavigationPaneHelper::updateCloudStorageRegistry() Utility::registryWalkSubKeys(HKEY_CURRENT_USER, nameSpaceKey, [&entriesToRemove](HKEY key, const QString &subKey) { const auto appName = Utility::registryGetKeyValue(key, subKey, QStringLiteral("ApplicationName")); - qCDebug(lcNavPane) << "Searching for user with subKey:" << subKey; + qCDebug(lcNavPane) << "Searching for user with subKey:" << subKey << "for appName:" << appName.toString(); if (appName.toString() == QLatin1String(APPLICATION_NAME) || appName.toString() == unbrandedApplicationName) { QUuid clsid{ subKey }; Q_ASSERT(!clsid.isNull()); entriesToRemove.append(clsid); + qCDebug(lcNavPane) << "Going to remove:" << subKey; } }); }