From d29d37b39cda45baef8c140c0283c8fc872447ea Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Mon, 29 Jul 2024 14:09:55 +0100 Subject: [PATCH] Fix issue with stepId being undefined when importing app (#14265) Co-authored-by: Adria Navarro --- packages/shared-core/src/sdk/documents/automations.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/shared-core/src/sdk/documents/automations.ts b/packages/shared-core/src/sdk/documents/automations.ts index 3663f7ae46..86cbee75f7 100644 --- a/packages/shared-core/src/sdk/documents/automations.ts +++ b/packages/shared-core/src/sdk/documents/automations.ts @@ -2,12 +2,12 @@ import { Automation, AutomationTriggerStepId } from "@budibase/types" export function isRowAction(automation: Automation) { const result = - automation.definition.trigger.stepId === AutomationTriggerStepId.ROW_ACTION + automation.definition.trigger?.stepId === AutomationTriggerStepId.ROW_ACTION return result } export function isAppAction(automation: Automation) { const result = - automation.definition.trigger.stepId === AutomationTriggerStepId.APP + automation.definition.trigger?.stepId === AutomationTriggerStepId.APP return result }