diff --git a/src/UnauthorizedError.ts b/src/UnauthorizedError.ts index d2a11d2..a1fa0cd 100644 --- a/src/UnauthorizedError.ts +++ b/src/UnauthorizedError.ts @@ -4,7 +4,7 @@ export class UnauthorizedError extends Error { constructor(code: string, error: { message: string }) { super(error.message) - this.message = error.message + this.name = 'UnauthorizedError' this.inner = error this.data = { message: this.message,