fix(wavl): use correct array method in isCorrect
Signed-off-by: Matej Focko <mfocko@redhat.com>
This commit is contained in:
parent
cb736602f8
commit
7217588536
1 changed files with 1 additions and 1 deletions
2
wavl.js
2
wavl.js
|
@ -5,7 +5,7 @@ class WAVLTree extends AVLTree {
|
||||||
}
|
}
|
||||||
|
|
||||||
nodeDifferences(node).forEach((childRank) => {
|
nodeDifferences(node).forEach((childRank) => {
|
||||||
if ([1, 2].findIndex(childRank) == -1) {
|
if ([1, 2].indexOf(childRank) == -1) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue