mirror of
https://github.com/nextcloud/desktop.git
synced 2024-10-24 21:35:47 +03:00
Prefer the use of _isDirectory over item._type == SyncFileItem::Directory
This commit is contained in:
parent
c5f8a2555d
commit
756e1c4a12
2 changed files with 3 additions and 5 deletions
|
@ -314,12 +314,10 @@ void Folder::bubbleUpSyncResult()
|
|||
|
||||
} else {
|
||||
// add new directories or remove gone away dirs to the watcher
|
||||
if (item._type == SyncFileItem::Directory &&
|
||||
item._instruction == CSYNC_INSTRUCTION_NEW ) {
|
||||
if (item._isDirectory && item._instruction == CSYNC_INSTRUCTION_NEW ) {
|
||||
FolderMan::instance()->addMonitorPath( alias(), path()+item._file );
|
||||
}
|
||||
if (item._type == SyncFileItem::Directory &&
|
||||
item._instruction == CSYNC_INSTRUCTION_REMOVE ) {
|
||||
if (item._isDirectory && item._instruction == CSYNC_INSTRUCTION_REMOVE ) {
|
||||
FolderMan::instance()->removeMonitorPath( alias(), path()+item._file );
|
||||
}
|
||||
|
||||
|
|
|
@ -79,7 +79,7 @@ bool PropagateItemJob::checkForProblemsWithShared(int httpStatusCode, const QStr
|
|||
PropagateItemJob *newJob = NULL;
|
||||
|
||||
if( httpStatusCode == 403 && _propagator->isInSharedDirectory(_item._file )) {
|
||||
if( _item._type != SyncFileItem::Directory ) {
|
||||
if( !_item._isDirectory ) {
|
||||
SyncFileItem downloadItem(_item);
|
||||
if (downloadItem._instruction == CSYNC_INSTRUCTION_NEW) {
|
||||
// don't try to recover pushing new files
|
||||
|
|
Loading…
Reference in a new issue