Skip to content

Commit c3dbd0c

Browse files
DaisyDogs07RafaelGSS
authored andcommitted
util: use primordials.ArrayPrototypeIndexOf instead of mutable method
PR-URL: #48586 Reviewed-By: Antoine du Hamel <[email protected]>
1 parent ea54784 commit c3dbd0c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/internal/util/inspect.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1215,7 +1215,7 @@ function getFunctionBase(value, constructor, tag) {
12151215
function identicalSequenceRange(a, b) {
12161216
for (let i = 0; i < a.length - 3; i++) {
12171217
// Find the first entry of b that matches the current entry of a.
1218-
const pos = b.indexOf(a[i]);
1218+
const pos = ArrayPrototypeIndexOf(b, a[i]);
12191219
if (pos !== -1) {
12201220
const rest = b.length - pos;
12211221
if (rest > 3) {

0 commit comments

Comments
 (0)