xiaoju-survey/server/src/exceptions/httpException.ts
2024-02-06 21:32:34 +08:00

11 lines
228 B
TypeScript

import { EXCEPTION_CODE } from 'src/enums/exceptionCode';
export class HttpException extends Error {
constructor(
public readonly message: string,
public readonly code: EXCEPTION_CODE,
) {
super(message);
}
}