Skip to content

Commit

Permalink
Add placeholder check
Browse files Browse the repository at this point in the history
  • Loading branch information
ivov committed Jun 17, 2024
1 parent af7f6db commit 87ebe4c
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions packages/editor-ui/src/components/MainHeader/MainHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -102,14 +102,16 @@ export default defineComponent({
this.dirtyState = this.uiStore.stateIsDirty;
this.syncTabsWithRoute(this.$route);
const workflowId = this.$route.params.name as string;
const workflow = await this.workflowsStore.fetchWorkflow(workflowId);
if (this.workflowsStore.workflow.id === PLACEHOLDER_EMPTY_WORKFLOW_ID) {
const workflowId = this.$route.params.name as string;
const workflow = await this.workflowsStore.fetchWorkflow(workflowId);
this.workflowsStore.setWorkflowId(workflowId);
this.workflowsStore.setWorkflowId(workflowId);
if (workflow.active) {
this.workflowsStore.setWorkflowActive(workflowId);
this.workflowsStore.setActive(workflow.active);
if (workflow.active) {
this.workflowsStore.setWorkflowActive(workflowId);
this.workflowsStore.setActive(workflow.active);
}
}
},
beforeUnmount() {
Expand Down

0 comments on commit 87ebe4c

Please sign in to comment.