1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 13:48:12 +00:00

LibJS: Call Array.prototype.findIndex() callback for empty elements

If the array value at the current index is empty, the callback will
be called with undefined as value.
This commit is contained in:
Linus Groh 2020-04-28 18:10:40 +01:00 committed by Andreas Kling
parent 823cc7bc1c
commit 3152559422
3 changed files with 27 additions and 7 deletions

View file

@ -17,7 +17,7 @@ try {
callbackCalled++;
a.pop();
});
assert(callbackCalled === 3);
assert(callbackCalled === 5);
console.log("PASS");
} catch (e) {