forked from profectus/Profectus
Fix links sometimes using nodes that were removed
This commit is contained in:
parent
4058fad711
commit
2c14b2193d
1 changed files with 3 additions and 3 deletions
|
@ -43,9 +43,9 @@ function updateNodes() {
|
|||
isDirty = false;
|
||||
nextTick(() => {
|
||||
boundingRect.value = resizeListener.value?.getBoundingClientRect();
|
||||
(Object.values(nodes.value) as FeatureNode[]).forEach(
|
||||
node => (node.rect = node.element.getBoundingClientRect())
|
||||
);
|
||||
(Object.values(nodes.value) as FeatureNode[])
|
||||
.filter(n => n) // Sometimes the values become undefined
|
||||
.forEach(node => (node.rect = node.element.getBoundingClientRect()));
|
||||
isDirty = true;
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue