diff --git a/lib/url-state-machine.js b/lib/url-state-machine.js index 4335573..9c33666 100644 --- a/lib/url-state-machine.js +++ b/lib/url-state-machine.js @@ -442,7 +442,7 @@ function domainToASCII(domain, beStrict = false) { } function trimControlChars(url) { - return url.replace(/^[\u0000-\u001F\u0020]+|[\u0000-\u001F\u0020]+$/ug, ""); + return url.replace(/^[\u0000-\u001F\u0020]+$/ug, ""); } function trimTabAndNewline(url) {