mirror of
https://github.com/abraunegg/onedrive
synced 2024-05-09 17:26:47 +02:00
Differenciate between OneNote objects and other unsupported objects (#870)
* Differenciate between OneNote objects and other unsupported objects
This commit is contained in:
parent
d3aa0032bc
commit
2a7e48b823
13
src/sync.d
13
src/sync.d
|
@ -1353,6 +1353,7 @@ final class SyncEngine
|
|||
}
|
||||
|
||||
// check the item type
|
||||
string path;
|
||||
if (!unwanted) {
|
||||
if (isItemFile(driveItem)) {
|
||||
log.vdebug("The item we are syncing is a file");
|
||||
|
@ -1362,14 +1363,22 @@ final class SyncEngine
|
|||
log.vdebug("The item we are syncing is a remote item");
|
||||
assert(isItemFolder(driveItem["remoteItem"]), "The remote item is not a folder");
|
||||
} else {
|
||||
log.vlog("This item type (", item.name, ") is not supported");
|
||||
// Why was this unwanted?
|
||||
path = itemdb.computePath(item.driveId, item.parentId) ~ "/" ~ item.name;
|
||||
// Microsoft OneNote container objects present as neither folder or file but has file size
|
||||
if ((!isItemFile(driveItem)) && (!isItemFolder(driveItem)) && (hasFileSize(driveItem))) {
|
||||
// Log that this was skipped as this was a Microsoft OneNote item and unsupported
|
||||
log.vlog("The Microsoft OneNote Notebook '", path, "' is not supported by this client");
|
||||
} else {
|
||||
// Log that this item was skipped as unsupported
|
||||
log.vlog("The OneDrive item '", path, "' is not supported by this client");
|
||||
}
|
||||
unwanted = true;
|
||||
log.vdebug("Flagging as unwanted: item type is not supported");
|
||||
}
|
||||
}
|
||||
|
||||
// check for selective sync
|
||||
string path;
|
||||
if (!unwanted) {
|
||||
// Is the item parent in the local database?
|
||||
if (itemdb.idInLocalDatabase(item.driveId, item.parentId)){
|
||||
|
|
Loading…
Reference in a new issue