Skip to content

Commit

Permalink
Make parameters more generic.
Browse files Browse the repository at this point in the history
  • Loading branch information
wparad committed Oct 31, 2023
1 parent b73ab01 commit eab6354
Show file tree
Hide file tree
Showing 2 changed files with 122 additions and 37 deletions.
3 changes: 2 additions & 1 deletion src/middlewares/openapi.request.validator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,8 @@ export class RequestValidator {
}
const errors = augmentAjvErrors([].concat(validator.errors ?? []));
const formattedErrors = ajvErrorsToValidatorError(errors);
const message = this.ajv.errorsText(errors, { dataVar: 'request' });
// const message = this.ajv.errorsText(errors, { dataVar: 'request' });
const message = formattedErrors.map(m => m.fullMessage).join(', ');
const error: BadRequest = new BadRequest({
path: req.route,
message: message
Expand Down
Loading

0 comments on commit eab6354

Please sign in to comment.