diff options
author | Hannah von Reth <hannah.vonreth@owncloud.com> | 2022-06-24 16:06:34 +0300 |
---|---|---|
committer | Fabian Müller <80399010+fmoc@users.noreply.github.com> | 2022-06-29 14:17:19 +0300 |
commit | 9b70ee3427fe7661a6f60de3e3016fbc4645058e (patch) | |
tree | 85ab3f91447f8488bb2b540e96b2da0a23cd9b8d /src/gui/owncloudgui.cpp | |
parent | 5dfd970c6802fece8de82ff8f6f6f36f28662fe7 (diff) |
Revert "Sync spaces to Spaces subfolder"
This reverts commit 0c4f977615fcd19ca46962b45ce15fcc912f51b6.
Fixes: #9821
Diffstat (limited to 'src/gui/owncloudgui.cpp')
-rw-r--r-- | src/gui/owncloudgui.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/gui/owncloudgui.cpp b/src/gui/owncloudgui.cpp index ec8212749..b0f9bac98 100644 --- a/src/gui/owncloudgui.cpp +++ b/src/gui/owncloudgui.cpp @@ -75,14 +75,12 @@ void setUpInitialSyncFolder(AccountStatePtr accountStatePtr, bool useVfs) if (drive->parseError().error == QJsonParseError::NoError) { const auto &drives = drive->drives(); if (!drives.isEmpty()) { - const QString localDir(accountStatePtr->account()->defaultSyncRoot()); - FolderMan::prepareFolder(localDir); - Utility::setupFavLink(localDir); + const QDir localDir(accountStatePtr->account()->defaultSyncRoot()); + FileSystem::setFolderMinimumPermissions(localDir.path()); + Utility::setupFavLink(localDir.path()); for (const auto &d : drives) { const QString name = GraphApi::Drives::getDriveDisplayName(d); - const QString mountPoint = localDir + QDir::separator() + GraphApi::Drives::getDriveMountPoint(d); - FolderMan::prepareFolder(mountPoint); - const QString folderName = FolderMan::instance()->findGoodPathForNewSyncFolder(mountPoint + QDir::separator() + name); + const QString folderName = FolderMan::instance()->findGoodPathForNewSyncFolder(localDir.filePath(name)); addFolder(folderName, {}, QUrl::fromEncoded(d.getRoot().getWebDavUrl().toUtf8()), name); } finalize(); |