fix(reactflowUtils.ts): add missing assignment of newSourceHandle to newEdge.data.sourceHandle to ensure data consistency

fix(reactflowUtils.ts): add missing assignment of newTargetHandle to newEdge.data.targetHandle to ensure data consistency
This commit is contained in:
anovazzi1 2023-09-14 20:22:29 -03:00
commit 4cdd66d1d3

View file

@ -731,6 +731,7 @@ export function ungroupNode(
if(inputTypes){
newTargetHandle.inputTypes = inputTypes;
}
newEdge.data.targetHandle = newTargetHandle;
newEdge.targetHandle = scapedJSONStringfy(newTargetHandle);
}
}
@ -740,6 +741,7 @@ export function ungroupNode(
newEdge.source = lastNode!.id;
let newSourceHandle: sourceHandleType = scapeJSONParse(newEdge.sourceHandle!);
newSourceHandle.id = lastNode!.id;
newEdge.data.sourceHandle = newSourceHandle;
newEdge.sourceHandle = scapedJSONStringfy(newSourceHandle);
}
updatedEdges.push(newEdge);