mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-29 20:28:57 +03:00
* fix for issue no. 1351
This commit is contained in:
parent
08c7be5350
commit
dfb20586ce
1 changed files with 13 additions and 7 deletions
|
@ -902,13 +902,19 @@ void Folder::slotItemCompleted(const SyncFileItemPtr &item)
|
|||
}
|
||||
|
||||
// add new directories or remove gone away dirs to the watcher
|
||||
if (item->isDirectory() && item->_instruction == CSYNC_INSTRUCTION_NEW) {
|
||||
if (_folderWatcher)
|
||||
_folderWatcher->addPath(path() + item->_file);
|
||||
}
|
||||
if (item->isDirectory() && item->_instruction == CSYNC_INSTRUCTION_REMOVE) {
|
||||
if (_folderWatcher)
|
||||
_folderWatcher->removePath(path() + item->_file);
|
||||
if (_folderWatcher && item->isDirectory()) {
|
||||
switch (item->_instruction) {
|
||||
case CSYNC_INSTRUCTION_NEW:
|
||||
_folderWatcher->addPath(path() + item->_file);
|
||||
break;
|
||||
case CSYNC_INSTRUCTION_REMOVE:
|
||||
_folderWatcher->removePath(path() + item->_file);
|
||||
break;
|
||||
case CSYNC_INSTRUCTION_RENAME:
|
||||
_folderWatcher->removePath(path() + item->_file);
|
||||
_folderWatcher->addPath(path() + item->destination());
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// Success and failure of sync items adjust what the next sync is
|
||||
|
|
Loading…
Reference in a new issue