mirror of
https://github.com/abraunegg/onedrive
synced 2024-06-03 06:22:18 +02:00
Handle renaming dotfiles to another dotfile when skip_dotfile=true in monitor mode (#843)
* Handle renaming dotfiles to another dotfile when skip_dotfile=true in monitor mode With thanks to @TheOnlyTrueJonathanHeard
This commit is contained in:
parent
caf51886cf
commit
3708828806
|
@ -3644,9 +3644,14 @@ final class SyncEngine
|
||||||
log.log("Moving ", from, " to ", to);
|
log.log("Moving ", from, " to ", to);
|
||||||
Item fromItem, toItem, parentItem;
|
Item fromItem, toItem, parentItem;
|
||||||
if (!itemdb.selectByPath(from, defaultDriveId, fromItem)) {
|
if (!itemdb.selectByPath(from, defaultDriveId, fromItem)) {
|
||||||
|
if (cfg.getValueBool("skip_dotfiles") && isDotFile(to)){
|
||||||
|
log.log("Skipping upload due to skip_dotfile = true");
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
uploadNewFile(to);
|
uploadNewFile(to);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (fromItem.parentId == null) {
|
if (fromItem.parentId == null) {
|
||||||
// the item is a remote folder, need to do the operation on the parent
|
// the item is a remote folder, need to do the operation on the parent
|
||||||
enforce(itemdb.selectByPathNoRemote(from, defaultDriveId, fromItem));
|
enforce(itemdb.selectByPathNoRemote(from, defaultDriveId, fromItem));
|
||||||
|
|
Loading…
Reference in a new issue