From 37bfde9c932ba4493a254a8dcfcc61535782ed37 Mon Sep 17 00:00:00 2001 From: Dean Date: Fri, 28 Jun 2024 16:23:00 +0100 Subject: [PATCH] Ensure removing a field from the update flow clears any row value. If not cleared, the field will remain in place. --- .../components/automation/SetupPanel/RowSelector.svelte | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/packages/builder/src/components/automation/SetupPanel/RowSelector.svelte b/packages/builder/src/components/automation/SetupPanel/RowSelector.svelte index ff904948b6..c5ae2fc24b 100644 --- a/packages/builder/src/components/automation/SetupPanel/RowSelector.svelte +++ b/packages/builder/src/components/automation/SetupPanel/RowSelector.svelte @@ -321,11 +321,15 @@ class:is-selected={Object.hasOwn(editableFields, field)} on:click={() => { if (Object.hasOwn(editableFields, field)) { - editableFields[field] = null + delete editableFields[field] + onChange({ + meta: { fields: editableFields }, + row: { [field]: null }, + }) } else { editableFields[field] = {} + onChange({ meta: { fields: editableFields } }) } - onChange({ meta: { fields: editableFields } }) }} >