From 76c98737059b46f92a6c8cb5ba36f8b1e3db3ae4 Mon Sep 17 00:00:00 2001 From: zadam Date: Wed, 10 Jan 2024 23:51:53 +0100 Subject: [PATCH] fix erase sync --- src/services/sync_update.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/services/sync_update.js b/src/services/sync_update.js index c1938a232..94091e9ef 100644 --- a/src/services/sync_update.js +++ b/src/services/sync_update.js @@ -73,7 +73,6 @@ function updateNormalEntity(remoteEC, remoteEntityRow, instanceId, updateContext if (localEC?.isErased) { eraseEntity(remoteEC); // make sure it's erased anyway updateContext.alreadyErased++; - return false; // we won't save entitychange in this case } else { eraseEntity(remoteEC); updateContext.erased++; @@ -91,7 +90,8 @@ function updateNormalEntity(remoteEC, remoteEntityRow, instanceId, updateContext updateContext.updated[remoteEC.entityName].push(remoteEC.entityId); } - if (!localEC || localEC.utcDateChanged < remoteEC.utcDateChanged + if (!localEC + || localEC.utcDateChanged < remoteEC.utcDateChanged || localEC.hash !== remoteEC.hash || localEC.isErased !== remoteEC.isErased ) {