Skip to content

Commit

Permalink
Update 'Skipping shared folder due to existing name conflict' check f…
Browse files Browse the repository at this point in the history
…or Business Shared Folders

* In looking on how to fix #1345, it appears that for some reason the logic behind syncing shared folders was not working (although it previously was). Update the logic to specifically check the DB for the required driveId & itemId before attempting to get that DB item.
  • Loading branch information
abraunegg committed Mar 17, 2021
1 parent 037a6b4 commit abfcb83
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/sync.d
Original file line number Diff line number Diff line change
Expand Up @@ -639,9 +639,12 @@ final class SyncEngine
// for each driveid in the existing driveIDsArray
foreach (searchDriveId; driveIDsArray) {
log.vdebug("searching database for: ", searchDriveId, " ", sharedFolderName);
if (itemdb.selectByPath(sharedFolderName, searchDriveId, databaseItem)) {
if (itemdb.idInLocalDatabase(searchDriveId, searchResult["remoteItem"]["id"].str)){
// Shared folder is present
log.vdebug("Found shared folder name in database");
itemInDatabase = true;
// Query the DB for the details of this item
itemdb.selectByPath(sharedFolderName, searchDriveId, databaseItem);
log.vdebug("databaseItem: ", databaseItem);
// Does the databaseItem.driveId == defaultDriveId?
if (databaseItem.driveId == defaultDriveId) {
Expand Down

0 comments on commit abfcb83

Please sign in to comment.