diff --git a/packages/editor-ui/src/stores/workflows.ts b/packages/editor-ui/src/stores/workflows.ts index af5d5992e1..43d9260f8c 100644 --- a/packages/editor-ui/src/stores/workflows.ts +++ b/packages/editor-ui/src/stores/workflows.ts @@ -538,7 +538,6 @@ export const useWorkflowsStore = defineStore(STORES.WORKFLOWS, { // TODO: Check if there is an error or whatever that is supposed to be returned return; } - const sourceData: IConnection = data.connection[0]; const destinationData: IConnection = data.connection[1]; diff --git a/packages/editor-ui/src/views/NodeView.vue b/packages/editor-ui/src/views/NodeView.vue index 7e3bc49ce6..22ee4d3679 100644 --- a/packages/editor-ui/src/views/NodeView.vue +++ b/packages/editor-ui/src/views/NodeView.vue @@ -2088,6 +2088,7 @@ export default mixins( this.connectTwoNodes(sourceNodeName, outputIndex, this.pullConnActiveNodeName, 0); this.pullConnActiveNodeName = null; + this.dropPrevented = true; } return; } @@ -2160,6 +2161,8 @@ export default mixins( ]; this.dropPrevented = true; + this.workflowsStore.addConnection({ connection: connectionData }); + this.uiStore.stateIsDirty = true; if (!this.suspendRecordingDetachedConnections) { this.historyStore.pushCommandToUndo(new AddConnectionCommand(connectionData)); }