From 7a2af7008b51ef2b99a071910ddc9f684a99344a Mon Sep 17 00:00:00 2001 From: filtered <176114999+webfiltered@users.noreply.github.com> Date: Wed, 5 Mar 2025 19:01:26 +1100 Subject: [PATCH] [Refactor] Rename to connectSlots (#708) - Follow-up on #703 - Changes name to match original intent --- src/LGraphNode.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/LGraphNode.ts b/src/LGraphNode.ts index d760bf6c4..d0845087f 100644 --- a/src/LGraphNode.ts +++ b/src/LGraphNode.ts @@ -2373,11 +2373,19 @@ export class LGraphNode implements Positionable, IPinnable, IColorable { } } - const link = this.connectInternal(output, target_node, input, afterRerouteId) + const link = this.connectSlots(output, target_node, input, afterRerouteId) return link ?? null } - connectInternal( + /** + * Connect two slots between two nodes + * @param output The output slot to connect + * @param inputNode The node that the input slot is on + * @param input The input slot to connect + * @param afterRerouteId The reroute ID to use for the link + * @returns The link that was created, or null if the connection was blocked + */ + connectSlots( output: INodeOutputSlot, inputNode: LGraphNode, input: INodeInputSlot,