We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6caa020 commit 0d2fafbCopy full SHA for 0d2fafb
src/error.ts
@@ -54,13 +54,17 @@ export function makeErrorForHideStackFrame<B extends new (...args: any[]) => Err
54
get errorStack() {
55
return this.#hiddenStack;
56
}
57
+ }
58
- // This is a workaround for wpt tests that expect that the error
59
- // constructor has a `name` property of the base class.
60
- get ["constructor"]() {
+ // This is a workaround for wpt tests that expect that the error
+ // constructor has a `name` property of the base class.
61
+ Object.defineProperty(HideStackFramesError.prototype, "constructor", {
62
+ get() {
63
return clazz;
- }
64
+ },
65
+ enumerable: false,
66
+ configurable: true,
67
+ });
68
69
return HideStackFramesError as any;
70
0 commit comments