mirror of
https://github.com/spacebarchat/server.git
synced 2026-06-08 04:21:40 +00:00
Include full AJV error on api
This commit is contained in:
@@ -144,7 +144,7 @@ export function route(opts: RouteOptions) {
|
||||
`[VALIDATION ERROR] ${req.method} ${req.originalUrl} - SCHEMA='${opts.requestBody}' -`,
|
||||
validate?.errors,
|
||||
);
|
||||
throw FieldErrors(fields);
|
||||
throw FieldErrors(fields, validate.errors!);
|
||||
}
|
||||
}
|
||||
next();
|
||||
|
||||
Reference in New Issue
Block a user