xiaoju-survey/server/src/exceptions/httpException.ts

11 lines
228 B
TypeScript
Raw Normal View History

2024-01-30 14:19:45 +00:00
import { EXCEPTION_CODE } from 'src/enums/exceptionCode';
export class HttpException extends Error {
constructor(
public readonly message: string,
public readonly code: EXCEPTION_CODE,
) {
super(message);
}
}