mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-30 03:01:54 +00:00
Fix disconnection from subgraph inputs (#4800)
This commit is contained in:
@@ -795,7 +795,10 @@ export class LinkConnector {
|
|||||||
*/
|
*/
|
||||||
disconnectLinks(): void {
|
disconnectLinks(): void {
|
||||||
for (const link of this.renderLinks) {
|
for (const link of this.renderLinks) {
|
||||||
if (link instanceof MovingLinkBase) {
|
if (
|
||||||
|
link instanceof MovingLinkBase ||
|
||||||
|
link instanceof ToInputFromIoNodeLink
|
||||||
|
) {
|
||||||
link.disconnect()
|
link.disconnect()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -135,4 +135,9 @@ export class ToInputFromIoNodeLink implements RenderLink {
|
|||||||
connectToRerouteOutput() {
|
connectToRerouteOutput() {
|
||||||
throw new Error('ToInputRenderLink cannot connect to an output.')
|
throw new Error('ToInputRenderLink cannot connect to an output.')
|
||||||
}
|
}
|
||||||
|
disconnect(): boolean {
|
||||||
|
if (!this.existingLink) return false
|
||||||
|
this.existingLink.disconnect(this.network, 'input')
|
||||||
|
return true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user