From 5011b6a51a350f19a8e70bd72656300dc0299dce Mon Sep 17 00:00:00 2001 From: zadam Date: Sat, 3 Jul 2021 20:52:40 +0200 Subject: [PATCH] don't try to fill additional properties for erased entities --- src/services/ws.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/services/ws.js b/src/services/ws.js index e37e06c9c..bb4b5bcf2 100644 --- a/src/services/ws.js +++ b/src/services/ws.js @@ -75,6 +75,10 @@ function sendMessageToAllClients(message) { } function fillInAdditionalProperties(entityChange) { + if (entityChange.isErased) { + return; + } + // fill in some extra data needed by the frontend if (entityChange.entityName === 'attributes') { entityChange.entity = sql.getRow(`SELECT * FROM attributes WHERE attributeId = ?`, [entityChange.entityId]);