Skip to content

Commit 69aaf8b

Browse files
anonrigruyadorno
authored andcommitted
lib: remove invalid parameter to toASCII
PR-URL: #48878 Backport-PR-URL: #48873 Refs: #48873 Refs: #48855 Refs: #48850 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
1 parent 2de9868 commit 69aaf8b

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

lib/url.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -427,10 +427,7 @@ Url.prototype.parse = function parse(url, parseQueryString, slashesDenoteHost) {
427427
// It only converts parts of the domain name that
428428
// have non-ASCII characters, i.e. it doesn't matter if
429429
// you call it with a domain that already is ASCII-only.
430-
431-
// Use lenient mode (`true`) to try to support even non-compliant
432-
// URLs.
433-
this.hostname = toASCII(this.hostname, true);
430+
this.hostname = toASCII(this.hostname);
434431

435432
// Prevent two potential routes of hostname spoofing.
436433
// 1. If this.hostname is empty, it must have become empty due to toASCII

0 commit comments

Comments
 (0)