fix(ES6): replace `array.includes` with es5 equivalent

This commit is contained in:
Martin Stamm 2022-02-18 11:52:37 +01:00 committed by fake-join[bot]
parent 1ba9de6dac
commit 7ff9be7c8a
2 changed files with 2 additions and 2 deletions

View File

@ -97,7 +97,7 @@ SubprocessCompatibility.prototype.createNewDiagrams = function(plane) {
var parent = element.parent; var parent = element.parent;
// parent is expanded, get nearest collapsed parent // parent is expanded, get nearest collapsed parent
while (parent && !collapsedElements.includes(parent)) { while (parent && collapsedElements.indexOf(parent) === -1) {
parent = parent.$parent; parent = parent.$parent;
} }

View File

@ -48,7 +48,7 @@ export default function ToggleCollapseConnectionBehaviour(
function handleConnection(c, incoming) { function handleConnection(c, incoming) {
if (allChildren.includes(c.source) && allChildren.includes(c.target)) { if (allChildren.indexOf(c.source) !== -1 && allChildren.indexOf(c.target) !== -1) {
return; return;
} }