Files
quicklanch-server/dist/app/utils/app_error.js
T

14 lines
324 B
JavaScript
Raw Normal View History

export class AppError extends Error {
statusCode;
constructor(message, statusCode, stack = '') {
super(message);
this.statusCode = statusCode;
if (stack) {
this.stack = stack;
}
else {
Error.captureStackTrace(this, this.constructor);
}
}
}