diff --git a/ext/web/01_dom_exception.js b/ext/web/01_dom_exception.js index 25eb85fc2b..d08a208dbd 100644 --- a/ext/web/01_dom_exception.js +++ b/ext/web/01_dom_exception.js @@ -96,7 +96,8 @@ }); this.#code = nameToCodeMapping[this.#name] ?? 0; - const error = new Error(`DOMException: ${this.#message}`); + const error = new Error(this.#message); + error.name = "DOMException"; ObjectDefineProperty(this, "stack", { value: error.stack, writable: true,