Files
edgeever/apps/api/src/app-error.ts
T

12 lines
236 B
TypeScript

export class AppError extends Error {
code: string;
status: number;
constructor(code: string, message: string, status = 400) {
super(message);
this.name = "AppError";
this.code = code;
this.status = status;
}
}