Fix reroute to wildcard & multi-typed slots (#769)

Use the same type check the rest of the connection process uses.
This commit is contained in:
filtered
2024-09-09 18:53:47 +10:00
committed by GitHub
parent 8b77dde55a
commit 0e01bb3c07

View File

@@ -128,8 +128,8 @@ app.registerExtension({
: null : null
if ( if (
inputType && inputType &&
inputType !== '*' && // @ts-expect-error Will self-resolve when LiteGraph types are generated
nodeOutType !== inputType !LiteGraph.isValidConnection(inputType, nodeOutType)
) { ) {
// The output doesnt match our input so disconnect it // The output doesnt match our input so disconnect it
node.disconnectInput(link.target_slot) node.disconnectInput(link.target_slot)