Get DatabaseErrorTest to pass
authorKevin Ottens <kevin.ottens@nextcloud.com>
Thu, 26 Nov 2020 18:08:17 +0000 (19:08 +0100)
committerKevin Ottens <kevin.ottens@nextcloud.com>
Tue, 15 Dec 2020 09:58:18 +0000 (10:58 +0100)
The E2EE code path would get the engine to go wrong in case of db error.
It's just better to have a failing upload or failing mkdir later in those
cases.

Emitting signals from a ctor is a bad idea anyway

Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
src/libsync/propagateremotemkdir.cpp
src/libsync/propagateupload.cpp

index d2fd737001b22d9a27edd7087ea6332c2f3e9b08..d1ac78aefa0c7ddc70ad3fa1c17beeef3105f199 100644 (file)
@@ -49,7 +49,6 @@ PropagateRemoteMkdir::PropagateRemoteMkdir(OwncloudPropagator *propagator, const
     SyncJournalFileRecord parentRec;
     bool ok = propagator->_journal->getFileRecord(parentPath, &parentRec);
     if (!ok) {
-        done(SyncFileItem::NormalError);
         return;
     }
 
index dd67be3ae359881e867c22ddc5a51ae7c84ab3be..7211f4fba88d8cf9247756931705473e57933729 100644 (file)
@@ -189,7 +189,6 @@ PropagateUploadFileCommon::PropagateUploadFileCommon(OwncloudPropagator *propaga
     SyncJournalFileRecord parentRec;
     bool ok = propagator->_journal->getFileRecord(parentPath, &parentRec);
     if (!ok) {
-        done(SyncFileItem::NormalError);
         return;
     }