chore(server): remove enable flag in mail config (#11680)

close #11625
This commit is contained in:
forehalo
2025-04-15 09:18:09 +00:00
parent b249939093
commit 7257f1b55b
15 changed files with 55 additions and 70 deletions

View File

@@ -275,6 +275,10 @@ export const USER_FRIENDLY_ERRORS = {
args: { message: 'string' },
message: ({ message }) => `HTTP request error, message: ${message}`,
},
email_service_not_configured: {
type: 'internal_server_error',
message: 'Email service is not configured.',
},
// Input errors
query_too_long: {

View File

@@ -54,6 +54,12 @@ export class HttpRequestError extends UserFriendlyError {
super('bad_request', 'http_request_error', message, args);
}
}
export class EmailServiceNotConfigured extends UserFriendlyError {
constructor(message?: string) {
super('internal_server_error', 'email_service_not_configured', message);
}
}
@ObjectType()
class QueryTooLongDataType {
@Field() max!: number
@@ -943,6 +949,7 @@ export enum ErrorNames {
BAD_REQUEST,
GRAPHQL_BAD_REQUEST,
HTTP_REQUEST_ERROR,
EMAIL_SERVICE_NOT_CONFIGURED,
QUERY_TOO_LONG,
VALIDATION_ERROR,
USER_NOT_FOUND,