From 8f98d8fa6ba2efeb7b50316b1dec1300b2db097f Mon Sep 17 00:00:00 2001 From: DrJKL Date: Mon, 18 May 2026 20:00:49 -0700 Subject: [PATCH] refactor(litegraph): mint clone UUID after configure() instead of up front Amp-Thread-ID: https://ampcode.com/threads/T-019e3d8c-b6b4-731e-b3fb-9bdb6fefb1ae Co-authored-by: Amp --- src/lib/litegraph/src/LGraphNode.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/lib/litegraph/src/LGraphNode.ts b/src/lib/litegraph/src/LGraphNode.ts index 3a5b183008..0373847e35 100644 --- a/src/lib/litegraph/src/LGraphNode.ts +++ b/src/lib/litegraph/src/LGraphNode.ts @@ -1022,11 +1022,9 @@ export class LGraphNode // @ts-expect-error Exceptional case: id is removed so that the graph can assign a new one on add. data.id = undefined - const clonedUuid = LiteGraph.use_uuids ? LiteGraph.uuidv4() : undefined - node.id = this.id node.configure(data) - if (clonedUuid !== undefined) node.id = clonedUuid + if (LiteGraph.use_uuids) node.id = LiteGraph.uuidv4() return node }