feat: 全局filter添加请求过于频繁的错误信息处理

This commit is contained in:
2025-12-19 20:11:59 +08:00
parent 4803145f86
commit 3ce02f8b28

View File

@@ -43,6 +43,10 @@ export class GlobalExceptionsFilter implements ExceptionFilter {
path: '/', path: '/',
}); });
} }
if (statusCode === HttpStatus.TOO_MANY_REQUESTS) {
errorResponse.message = '请求过于频繁,请稍后再试';
}
} else { } else {
Logger.warn(exception, request.path); Logger.warn(exception, request.path);
} }