开启后端严格空值检查
This commit is contained in:
@@ -45,8 +45,8 @@ export function buildErrorPayload(error: unknown, fallbackMessage: string) {
|
||||
export function sendRouteError(
|
||||
res: Response,
|
||||
error: unknown,
|
||||
fallbackMessage: string,
|
||||
scope: string
|
||||
fallbackMessage = "服务内部错误",
|
||||
scope = "[route]"
|
||||
): void {
|
||||
const classification = classifyRouteError(error);
|
||||
const logger = classification.statusCode >= 500 ? logError : logWarn;
|
||||
|
||||
Reference in New Issue
Block a user