We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0d8338f commit 61c5bfaCopy full SHA for 61c5bfa
src/core/graph/widgets/dynamicWidgets.ts
@@ -84,12 +84,14 @@ function COMFY_DYNAMICCOMBO_V3(
84
}
85
const addedInputs = node
86
.spliceInputs(startingInputLength)
87
- .filter(
88
- (addedInput) =>
89
- !node.inputs.some(
90
- (existingInput) => addedInput.name === existingInput.name
91
- )
92
+ .map((addedInput) => {
+ const existingInput = node.inputs.findIndex(
+ (existingInput) => addedInput.name === existingInput.name
+ )
+ return existingInput === -1
+ ? addedInput
93
+ : node.spliceInputs(existingInput, 1)[0]
94
+ })
95
//assume existing inputs are in correct order
96
node.spliceInputs(inputInsertionPoint, 0, ...addedInputs)
97
node.size[1] = node.computeSize([...node.size])[1]
0 commit comments