Fix loop block label update bug (#1496)

This commit is contained in:
Shuchang Zheng
2025-01-06 05:15:49 -08:00
committed by GitHub
parent 74c8dd45f5
commit 7abd5312c9

View File

@@ -1194,10 +1194,11 @@ function getUpdatedNodesAfterLabelUpdateForParameterKeys(
...node,
data: {
...node.data,
loopValue:
node.data.loopValue === getOutputParameterKey(oldLabel)
label: node.id === id ? newLabel : node.data.label,
loopVariableReference:
node.data.loopVariableReference === getOutputParameterKey(oldLabel)
? getOutputParameterKey(newLabel)
: node.data.loopValue,
: node.data.loopVariableReference,
},
};
}