Fix id handling on update

This commit is contained in:
Joao Correia
2025-02-01 23:14:17 +00:00
parent ac539332e6
commit b684262759
5 changed files with 7 additions and 5 deletions

View File

@@ -65,7 +65,7 @@ export default function Home({ user, workflow, workflowEntityApprovers }: Props)
completed: step.completed,
completedBy: step.completedBy || undefined,
completedDate: step.completedDate || undefined,
assignees: step.assignees.map(id => id),
assignees: step.assignees,
firstStep: step.firstStep || false,
finalStep: step.finalStep || false,
onDelete: undefined,
@@ -98,7 +98,6 @@ export default function Home({ user, workflow, workflowEntityApprovers }: Props)
...updatedWorkflow,
steps: updatedWorkflow.steps.map(step => ({
...step,
completed: false,
assignees: step.assignees.filter((assignee): assignee is string => assignee !== null && assignee !== undefined)
}))
};