update: correctly overwrite nodes on re-parsing

Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
Braks
2021-12-20 19:29:52 +01:00
parent 7367345d8d
commit d2ac41e4f7
+2 -2
View File
@@ -85,8 +85,8 @@ export const parseNode = (node: Node, nodeExtent: CoordinateExtent, defaults?: P
: defaults
return {
...node,
...(defaults as GraphNode),
...node,
id: node.id.toString(),
}
}
@@ -111,8 +111,8 @@ export const parseEdge = (edge: Edge, defaults?: Partial<GraphEdge>): GraphEdge
: defaults
return {
...edge,
...(defaults as GraphEdge),
...edge,
id: edge.id.toString(),
}
}