From c6b586de33b6ac208d3de83b304bfe50f13a4292 Mon Sep 17 00:00:00 2001 From: Joyee Cheung Date: Sun, 5 Feb 2017 03:57:11 +0800 Subject: [PATCH] benchmark: fix first call to URL in useWHATWG PR-URL: https://github.com/nodejs/node/pull/11170 Reviewed-By: James M Snell Reviewed-By: Timothy Gu --- benchmark/url/legacy-vs-whatwg-url-parse.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/url/legacy-vs-whatwg-url-parse.js b/benchmark/url/legacy-vs-whatwg-url-parse.js index ca7a48466c7dc3..64533e67e4a46a 100644 --- a/benchmark/url/legacy-vs-whatwg-url-parse.js +++ b/benchmark/url/legacy-vs-whatwg-url-parse.js @@ -34,7 +34,7 @@ function useLegacy(n, input) { } function useWHATWG(n, input) { - var noDead = url.parse(input); + var noDead = new URL(input); bench.start(); for (var i = 0; i < n; i += 1) { noDead = new URL(input);