Skip to content

Commit

Permalink
benchmark: use Object.hasOwn() instead of hasOwnProperty()
Browse files Browse the repository at this point in the history
PR-URL: #41769
Reviewed-By: Mestery <mestery@protonmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
  • Loading branch information
Trott authored and ruyadorno committed Feb 7, 2022
1 parent 86644b9 commit 28b95a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion benchmark/http/check_invalid_header_char.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ const bench = common.createBenchmark(main, {

function main({ n, input }) {
let inputs = [input];
if (groupedInputs.hasOwnProperty(input)) {
if (Object.hasOwn(groupedInputs, input)) {
inputs = groupedInputs[input];
}

Expand Down

0 comments on commit 28b95a5

Please sign in to comment.