-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CompensateBoundaryEventBehavior.js: fail 'shape.replace' event handler when the targetElement
is undefined
#2073
Comments
I can reproduce this in the
|
We see these failures when updating the element template repository dependencies, too: bpmn-io/bpmn-js-element-templates#40 |
This sounds critical :/ |
I had a closer look, and in the compensation PR I assumed that |
Closed via #2074 |
Fixes a replace issue (originally reported via bpmn-io/bpmn-js#2073).
Fixes a replace issue (originally reported via bpmn-io/bpmn-js#2073).
fix: support core replace in compensation behavior (bpmn-io/bpmn-js#2073) --- Full changelog: https://github.com/bpmn-io/bpmn-js/blob/develop/CHANGELOG.md#1632
fix: support core replace in compensation behavior (bpmn-io/bpmn-js#2073) --- Full changelog: https://github.com/bpmn-io/bpmn-js/blob/develop/CHANGELOG.md#1632
Describe the Bug
There is a bug while using bpmn-js-element-templates with bpmn-js@16.3.0 after removing an element template:
It is caused by calling https://github.com/bpmn-io/bpmn-js-element-templates/blob/main/src/element-templates/cmd/RemoveElementTemplateHandler.js#L46 without
hints.targetElement
As we can see from line https://github.com/bpmn-io/bpmn-js/blob/develop/lib/features/modeling/behavior/CompensateBoundaryEventBehavior.js#L95 the
targetElement
could be undefined.As solution, we could check it for undefined before getting properties like
targetElement.type
ortargetElement.eventDefinitionType
on 100,101,115 linesSteps to Reproduce
Expected Behavior
Element template is removed without errors
Environment
The text was updated successfully, but these errors were encountered: