Update workflow version struct (#6716)
We want to avoid the nested structure of active pieces. Steps to execute will now be separated from the trigger. It will be an array executed sequentially. For now a step can only be an action. But at some point it will also be a branch or a loop
This commit is contained in:
@ -27,9 +27,9 @@ export function assertWorkflowVersionIsValid(
|
||||
);
|
||||
}
|
||||
|
||||
if (!workflowVersion.trigger.nextAction) {
|
||||
if (!workflowVersion.steps || workflowVersion.steps.length === 0) {
|
||||
throw new WorkflowTriggerException(
|
||||
'No next action provided in trigger',
|
||||
'No steps provided in workflow version',
|
||||
WorkflowTriggerExceptionCode.INVALID_WORKFLOW_TRIGGER,
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user