From 49eb887cc6325e14211ec4a241ffc4ac98f0f7a9 Mon Sep 17 00:00:00 2001 From: Kenta Moriuchi Date: Tue, 2 May 2023 19:15:45 +0900 Subject: refactor(core): Use `ObjectHasOwn` instead of `ObjectPrototypeHasOwnProperty` (#18952) ES2022 `Object.hasOwn` can be used in snapshot, so I migrate to use it. --- cli/js/40_testing.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cli/js/40_testing.js') diff --git a/cli/js/40_testing.js b/cli/js/40_testing.js index 8afcb74ee..e269b9c9f 100644 --- a/cli/js/40_testing.js +++ b/cli/js/40_testing.js @@ -21,7 +21,7 @@ const { MapPrototypeSet, MathCeil, ObjectKeys, - ObjectPrototypeHasOwnProperty, + ObjectHasOwn, ObjectPrototypeIsPrototypeOf, Promise, SafeArrayIterator, @@ -166,7 +166,7 @@ function assertOps(fn) { const details = []; for (const key in post.ops) { - if (!ObjectPrototypeHasOwnProperty(post.ops, key)) { + if (!ObjectHasOwn(post.ops, key)) { continue; } const preOp = pre.ops[key] ?? -- cgit v1.2.3