diff --git a/src/lib/litegraph/src/LGraphNode.ts b/src/lib/litegraph/src/LGraphNode.ts index b65b0d7f49..23326e24ff 100644 --- a/src/lib/litegraph/src/LGraphNode.ts +++ b/src/lib/litegraph/src/LGraphNode.ts @@ -2569,7 +2569,12 @@ export class LGraphNode findInputByType( type: ISlotType ): { index: number; slot: INodeInputSlot } | undefined { - return findFreeSlotOfType(this.inputs, type, (input) => input.link == null) + return findFreeSlotOfType( + this.inputs, + type, + (input) => + input.link == null || !!this.graph?.getLink(input.link)?._dragging + ) } /**