mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-27 17:52:16 +00:00
[Bug] Fix slot link state corruption on moving link between sockets (#882)
Ref: https://github.com/Comfy-Org/litegraph.js/issues/881 This PR fixes the corrupted link state when moving link from one input socket to another.
This commit is contained in:
@@ -42,6 +42,7 @@ export class MovingInputLink extends MovingLinkBase {
|
||||
connectToInput(inputNode: LGraphNode, input: INodeInputSlot, events: LinkConnectorEventTarget): LLink | null | undefined {
|
||||
if (input === this.inputSlot) return
|
||||
|
||||
this.inputNode.disconnectInput(this.inputIndex, true)
|
||||
const link = this.outputNode.connectSlots(this.outputSlot, inputNode, input, this.fromReroute?.id)
|
||||
if (link) events.dispatch("input-moved", this)
|
||||
return link
|
||||
|
||||
Reference in New Issue
Block a user