chore(deps): update dependency express-validator --> v7
This MR contains the following updates:
Package | Change | Age | Adoption | Passing | Confidence |
---|---|---|---|---|---|
express-validator (source) | ^6.10.0 -> ^7.0.0 |
Release Notes
express-validator/express-validator
v7.0.1
- Fixed
checkSchema()
warning that known validators are unknown when its value isfalse
- #1223
v7.0.0
💥
Breaking changes - Minimum supported Node.js version is now 14+
- Removed deprecated APIs - #993
- Import paths
express-validator/check
andexpress-validator/filter
- Sanitization-only middlewares (e.g.
sanitize()
,sanitizeBody()
, etc) - Deprecated TypeScript types (
ValidationParamSchema
andValidationSchema
)
- Import paths
-
isObject()
validator now assumesoptions.strict = true
by default - Validation errors changed shape
- Field validation errors
param
property has been renamed topath
-
oneOf()
validation errors no longer have aparam: '_error'
property
- Field validation errors
- (TypeScript only) The
ValidationError
type is now a discriminated union, it might be necessary to useswitch
orif
statements to check that you're dealing with the type that you want to debug/format -
oneOf()
signature changed: fromoneOf(chains, message)
tooneOf(chains, options: { message, errorType })
-
oneOf()
default error structure now groups errors by their... validation group!, instead of in a flat list
Checkout the migration guide for examples on how to work around some of these: https://express-validator.github.io/docs/migration-v6-to-v7
✨
New features - Added validation for no unknown fields - #558, #578, #612, #1148, #809, #927, #1204
- Added globstars (deep wildcard) support - #790, #1137, #1216
- Added support for multiple custom validators/sanitizers in
checkSchema()
- #552, #1180 - Added request-level bail - #1100, #1214
- Added a
ExpressValidator
class which allows adding "persistent" custom validators, sanitizers, and options - #1077, #1079, #1209 - Added
oneOf()
support to.if()
- #1170 - Added new error types to
oneOf()
- #956, #1022
🐛
Bug fixes - Validating/sanitizing arrays no longer drops all but the first value - #791, #755, #704, #1002
- Added missing
ko-KR
toMobilePhoneLocale
- #1218, #1219 - Don't silently fail when setting
withMessage
andnot
in schemas - #664
New Contributors
- @Yoowatney made their first contribution in https://github.com/express-validator/express-validator/pull/1219
Full Changelog: https://github.com/express-validator/express-validator/compare/v6.15.0...v7.0.0
v6.15.0
What's Changed
- chore(deps): bump ua-parser-js from 0.7.32 to 0.7.33 by @dependabot in https://github.com/express-validator/express-validator/pull/1208
- chore(deps): bump eta from 1.12.3 to 2.0.0 by @dependabot in https://github.com/express-validator/express-validator/pull/1211
- chore(deps): bump http-cache-semantics from 4.1.0 to 4.1.1 by @dependabot in https://github.com/express-validator/express-validator/pull/1210
- feat: update to support validator 13.9.0 by @fedeci in https://github.com/express-validator/express-validator/pull/1212
Full Changelog: https://github.com/express-validator/express-validator/compare/v6.14.3...v6.15.0
v6.14.3
What's Changed
- docs: fixed typo in sanitization chain example by @ankushknr19 in https://github.com/express-validator/express-validator/pull/1195
- fixed infinite recursion when the request has a field called
*
(#1205)
New Contributors
- @ankushknr19 made their first contribution in https://github.com/express-validator/express-validator/pull/1195
Full Changelog: https://github.com/express-validator/express-validator/compare/v6.14.2...v6.14.3
v6.14.2
What's Changed
- correctly run
.matches
when passing regex object by @tonysamperi in https://github.com/express-validator/express-validator/pull/1156
New Contributors
- @tonysamperi made their first contribution in https://github.com/express-validator/express-validator/pull/1156
Full Changelog: https://github.com/express-validator/express-validator/compare/v6.14.1...v6.14.2
v6.14.1
What's Changed
- Add
validationResult()
for schema validation example by @daenamkim in https://github.com/express-validator/express-validator/pull/1120 - chore(deps): bump shelljs from 0.8.4 to 0.8.5 by @dependabot in https://github.com/express-validator/express-validator/pull/1128
- chore(deps): bump ajv from 6.11.0 to 6.12.6 by @dependabot in https://github.com/express-validator/express-validator/pull/1129
- chore(deps): bump prismjs from 1.25.0 to 1.27.0 by @dependabot in https://github.com/express-validator/express-validator/pull/1135
- docs: remove dependencies status badge by @gustavohenke in https://github.com/express-validator/express-validator/pull/1131
- chore(deps): bump minimist from 1.2.5 to 1.2.6 by @dependabot in https://github.com/express-validator/express-validator/pull/1142
- chore(deps): bump async from 2.6.3 to 2.6.4 by @dependabot in https://github.com/express-validator/express-validator/pull/1147
- Add missing
SK
postal code - #1144
New Contributors
- @daenamkim made their first contribution in https://github.com/express-validator/express-validator/pull/1120
Full Changelog: https://github.com/express-validator/express-validator/compare/v6.14.0...v6.14.1
v6.14.0
What's Changed
- feat: update
validator
to13.7
by @fedeci in https://github.com/express-validator/express-validator/pull/1115 - chore(deps): bump tmpl from 1.0.4 to 1.0.5 by @dependabot in https://github.com/express-validator/express-validator/pull/1116
- chore(deps): bump path-parse from 1.0.6 to 1.0.7 by @dependabot in https://github.com/express-validator/express-validator/pull/1118
- chore(deps): bump prismjs from 1.24.0 to 1.25.0 by @dependabot in https://github.com/express-validator/express-validator/pull/1117
Full Changelog: https://github.com/express-validator/express-validator/compare/v6.13.0...v6.14.0
v6.13.0
What's Changed
- docs: warn users about bad practice by @hariprasadkc in https://github.com/express-validator/express-validator/pull/1094
- schema usage according to documentation results in Error by @fkarg in https://github.com/express-validator/express-validator/pull/1095
- v6.13 features by @fedeci in https://github.com/express-validator/express-validator/pull/1091
New Contributors
- @hariprasadkc made their first contribution in https://github.com/express-validator/express-validator/pull/1094
- @fkarg made their first contribution in https://github.com/express-validator/express-validator/pull/1095
Full Changelog: https://github.com/express-validator/express-validator/compare/v6.12.2...v6.13.0
v6.12.2
Fixes:
-
#1072: add type for
checkSchema
function return -
#1092, #1086: correctly allow falsy values as options in
checkSchema
v6.12.1
v6.12.0
-
#1047, #1049 - make
withMessage
actually override a custom validator's message -
#1026, #1037 - add missing arguments of
isAlphanumeric
v6.11.1
v6.11.0
v6.10.1
Configuration
-
If you want to rebase/retry this MR, check this box.