api/processing: slightly reformat code related to zod
This commit is contained in:
@@ -72,7 +72,9 @@ export function createResponse(responseType, responseData) {
|
||||
}
|
||||
|
||||
export function normalizeRequest(request) {
|
||||
return apiSchema.safeParseAsync(request).catch(() => ({ success: false }));
|
||||
return apiSchema.safeParseAsync(request).catch(() => (
|
||||
{ success: false }
|
||||
));
|
||||
}
|
||||
|
||||
export function getIP(req) {
|
||||
|
||||
Reference in New Issue
Block a user