diff --git a/lib/internal/url.js b/lib/internal/url.js index 61bb8ee991ada57..af15cb40dc757d0 100644 --- a/lib/internal/url.js +++ b/lib/internal/url.js @@ -838,7 +838,9 @@ class URL { get href() { // URLSearchParams is used on demand, and stores the search if it's used. if (this.#searchParams) { - return bindingUrl.update(this.#context.href, updateActions.kSearch, this.#searchParams.toString()); + return StringPrototypeSlice(this.#context.href, 0, this.#context.hash_start - 1) + + this.#searchParams.toString() + + StringPrototypeSlice(this.#context.href, this.#context.hash_start); } return this.#context.href; }