Skip to content

Commit 66fb032

Browse files
DaisyDogs07ruyadorno
authored andcommitted
util: use primordials.ArrayPrototypeIndexOf instead of mutable method
PR-URL: #48586 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
1 parent 10495ad commit 66fb032

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
@@ -1216,7 +1216,7 @@ function getFunctionBase(value, constructor, tag) {
12161216
function identicalSequenceRange(a, b) {
12171217
for (let i = 0; i < a.length - 3; i++) {
12181218
// Find the first entry of b that matches the current entry of a.
1219-
const pos = b.indexOf(a[i]);
1219+
const pos = ArrayPrototypeIndexOf(b, a[i]);
12201220
if (pos !== -1) {
12211221
const rest = b.length - pos;
12221222
if (rest > 3) {

0 commit comments

Comments
 (0)