fix(API): Do not add starting node on workflow creation (#6686)

* fix(API): Do not add starting node on workflow creation

* chore: Remove comment
This commit is contained in:
Iván Ovejero
2023-07-18 14:03:19 +02:00
committed by GitHub
parent 2a6cd26def
commit 92192fbd61
7 changed files with 37 additions and 38 deletions

View File

@@ -64,7 +64,7 @@ import { WorkflowRunner } from '@/WorkflowRunner';
import { ExternalHooks } from '@/ExternalHooks';
import { whereClause } from './UserManagement/UserManagementHelper';
import { WorkflowsService } from './workflows/workflows.services';
import { START_NODES } from './constants';
import { STARTING_NODES } from './constants';
import { webhookNotFoundErrorMessage } from './utils';
import { In } from 'typeorm';
@@ -793,7 +793,7 @@ export class ActiveWorkflowRunner {
settings: workflowData.settings,
});
const canBeActivated = workflowInstance.checkIfWorkflowCanBeActivated(START_NODES);
const canBeActivated = workflowInstance.checkIfWorkflowCanBeActivated(STARTING_NODES);
if (!canBeActivated) {
Logger.error(`Unable to activate workflow "${workflowData.name}"`);
throw new Error(