Skip to content

Commit 366cf73

Browse files
committed
disable use of bulk upload for small files
this feature causes many issues with impact on users so we prefer to disable it again Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
1 parent 180095c commit 366cf73

File tree

1 file changed

+2
-22
lines changed

1 file changed

+2
-22
lines changed

src/libsync/owncloudpropagator.cpp

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1091,29 +1091,9 @@ Result<Vfs::ConvertToPlaceholderResult, QString> OwncloudPropagator::staticUpdat
10911091

10921092
bool OwncloudPropagator::isDelayedUploadItem(const SyncFileItemPtr &item) const
10931093
{
1094-
const auto checkFileShouldBeEncrypted = [this] (const SyncFileItemPtr &item) -> bool {
1095-
const auto path = item->_file;
1096-
const auto slashPosition = path.lastIndexOf('/');
1097-
const auto parentPath = slashPosition >= 0 ? path.left(slashPosition) : QString();
1098-
1099-
SyncJournalFileRecord parentRec;
1100-
bool ok = _journal->getFileRecord(parentPath, &parentRec);
1101-
if (!ok) {
1102-
return false;
1103-
}
1104-
1105-
const auto accountPtr = account();
1094+
Q_UNUSED(item)
11061095

1107-
if (!parentRec.isValid() ||
1108-
!parentRec.isE2eEncrypted()) {
1109-
return false;
1110-
}
1111-
1112-
return true;
1113-
};
1114-
1115-
return account()->capabilities().bulkUpload() && !_scheduleDelayedTasks && !item->isEncrypted() && _syncOptions.minChunkSize() > item->_size
1116-
&& !isInBulkUploadBlackList(item->_file) && !checkFileShouldBeEncrypted(item);
1096+
return false;
11171097
}
11181098

11191099
void OwncloudPropagator::setScheduleDelayedTasks(bool active)

0 commit comments

Comments
 (0)