Skip to content

Commit 7465a5e

Browse files
committed
fix(core/GrahicsFactory): account for removed shapes on updateContainments
Related to bpmn-io/bpmn-js#2269
1 parent 89f79d5 commit 7465a5e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/core/GraphicsFactory.js

+5
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,11 @@ GraphicsFactory.prototype.updateContainments = function(elements) {
192192
forEach(children.slice().reverse(), function(child) {
193193
var childGfx = elementRegistry.getGraphics(child);
194194

195+
// shape was removed
196+
if (!childGfx) {
197+
return;
198+
}
199+
195200
prependTo(childGfx.parentNode, childrenGfx);
196201
});
197202
});

0 commit comments

Comments
 (0)