Skip to content

The open alternative to Salesforce, designed for AI.

Fix discard workflow draft (#12230)

Thomas Trompettecced069d2851
diff --git a/packages/twenty-front/src/modules/workflow/hooks/useWorkflowWithCurrentVersion.ts b/packages/twenty-front/src/modules/workflow/hooks/useWorkflowWithCurrentVersion.ts
index d3a4920f81d..df362bc9fe1 100644
--- a/packages/twenty-front/src/modules/workflow/hooks/useWorkflowWithCurrentVersion.ts
+++ b/packages/twenty-front/src/modules/workflow/hooks/useWorkflowWithCurrentVersion.ts
@@ -18,7 +18,17 @@ export const useWorkflowWithCurrentVersion = (
name: true,
statuses: true,
lastPublishedVersionId: true,
- versions: true,
+ versions: {
+ id: true,
+ status: true,
+ name: true,
+ steps: true,
+ trigger: true,
+ workflowId: true,
+ deletedAt: true,
+ createdAt: true,
+ updatedAt: true,
+ },
},
skip: !isDefined(workflowId),
});