fix(server): should use error instance stack (#11392)
This commit is contained in:
1 file changed
+2
-2
@@ -116,8 +116,8 @@ export class UserFriendlyError extends Error {
|
|||||||
|
|
||||||
get stacktrace() {
|
get stacktrace() {
|
||||||
return this.name === 'internal_server_error'
|
return this.name === 'internal_server_error'
|
||||||
? ((this.cause as Error)?.stack ?? super.stack)
|
? ((this.cause as Error)?.stack ?? this.stack)
|
||||||
: super.stack;
|
: this.stack;
|
||||||
}
|
}
|
||||||
|
|
||||||
toJSON() {
|
toJSON() {
|
||||||
|
|||||||
Reference in new issue
Block a user