Skip to content

Commit 7ee52a9

Browse files
committed
- Bump class-validator
- Assert the new error message for enum
1 parent 48ccf9f commit 7ee52a9

File tree

3 files changed

+23
-24
lines changed

3 files changed

+23
-24
lines changed

redisinsight/api/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
"axios": "^0.25.0",
5959
"body-parser": "^1.19.0",
6060
"class-transformer": "^0.2.3",
61-
"class-validator": "^0.12.2",
61+
"class-validator": "^0.14.0",
6262
"connect-timeout": "^1.9.0",
6363
"date-fns": "^2.29.3",
6464
"detect-port": "^1.5.1",

redisinsight/api/test/helpers/test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ export const checkResponseBody = (body, expected) => {
131131

132132
const defaultValidationErrorMessages = {
133133
'any.required': '{#label} should not be null or undefined',
134-
'any.only': '{#label} must be a valid enum value',
134+
'any.only': '{#label} must be one of the following values',
135135
'array.base': '{#label} must be an array',
136136
'string.base': `{#label} must be a string`,
137137
'string.empty': `{#label} should not be null or undefined`,

redisinsight/api/yarn.lock

Lines changed: 21 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1188,10 +1188,10 @@
11881188
resolved "https://registry.yarnpkg.com/@types/triple-beam/-/triple-beam-1.3.2.tgz#38ecb64f01aa0d02b7c8f4222d7c38af6316fef8"
11891189
integrity sha512-txGIh+0eDFzKGC25zORnswy+br1Ha7hj5cMVwKIU7+s0U2AxxJru/jZSMU6OC9MJWP6+pc/hc6ZjyZShpsyY2g==
11901190

1191-
"@types/validator@13.0.0":
1192-
version "13.0.0"
1193-
resolved "https://registry.yarnpkg.com/@types/validator/-/validator-13.0.0.tgz#365f1bf936aeaddd0856fc41aa1d6f82d88ee5b3"
1194-
integrity sha512-WAy5txG7aFX8Vw3sloEKp5p/t/Xt8jD3GRD9DacnFv6Vo8ubudAsRTXgxpQwU0mpzY/H8U4db3roDuCMjShBmw==
1191+
"@types/validator@^13.7.10":
1192+
version "13.7.17"
1193+
resolved "https://registry.yarnpkg.com/@types/validator/-/validator-13.7.17.tgz#0a6d1510395065171e3378a4afc587a3aefa7cc1"
1194+
integrity sha512-aqayTNmeWrZcvnG2MG9eGYI6b7S5fl+yKgPs6bAjOTwPS316R5SxBGKvtSExfyoJU7pIeHJfsHI0Ji41RVMkvQ==
11951195

11961196
"@types/yargs-parser@*":
11971197
version "21.0.0"
@@ -2272,15 +2272,14 @@ class-utils@^0.3.5:
22722272
isobject "^3.0.0"
22732273
static-extend "^0.1.1"
22742274

2275-
class-validator@^0.12.2:
2276-
version "0.12.2"
2277-
resolved "https://registry.yarnpkg.com/class-validator/-/class-validator-0.12.2.tgz#2ceb72f88873e9c714cf5f9c278cbc71f6f6c8ef"
2278-
integrity sha512-TDzPzp8BmpsbPhQpccB3jMUE/3pK0TyqamrK0kcx+ZeFytMA+O6q87JZZGObHHnoo9GM8vl/JppIyKWeEA/EVw==
2275+
class-validator@^0.14.0:
2276+
version "0.14.0"
2277+
resolved "https://registry.yarnpkg.com/class-validator/-/class-validator-0.14.0.tgz#40ed0ecf3c83b2a8a6a320f4edb607be0f0df159"
2278+
integrity sha512-ct3ltplN8I9fOwUd8GrP8UQixwff129BkEtuWDKL5W45cQuLd19xqmTLu5ge78YDm/fdje6FMt0hGOhl0lii3A==
22792279
dependencies:
2280-
"@types/validator" "13.0.0"
2281-
google-libphonenumber "^3.2.8"
2282-
tslib ">=1.9.0"
2283-
validator "13.0.0"
2280+
"@types/validator" "^13.7.10"
2281+
libphonenumber-js "^1.10.14"
2282+
validator "^13.7.0"
22842283

22852284
clean-stack@^2.0.0:
22862285
version "2.2.0"
@@ -4020,11 +4019,6 @@ globby@^11.0.3:
40204019
merge2 "^1.4.1"
40214020
slash "^3.0.0"
40224021

4023-
google-libphonenumber@^3.2.8:
4024-
version "3.2.32"
4025-
resolved "https://registry.yarnpkg.com/google-libphonenumber/-/google-libphonenumber-3.2.32.tgz#63c48a9c247b64a3bc2eec21bdf3fcfbf2e148c0"
4026-
integrity sha512-mcNgakausov/B/eTgVeX8qc8IwWjRrupk9UzZZ/QDEvdh5fAjE7Aa211bkZpZj42zKkeS6MTT8avHUwjcLxuGQ==
4027-
40284022
gopd@^1.0.1:
40294023
version "1.0.1"
40304024
resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.0.1.tgz#29ff76de69dac7489b7c0918a5788e56477c332c"
@@ -5376,6 +5370,11 @@ levn@~0.3.0:
53765370
prelude-ls "~1.1.2"
53775371
type-check "~0.3.2"
53785372

5373+
libphonenumber-js@^1.10.14:
5374+
version "1.10.37"
5375+
resolved "https://registry.yarnpkg.com/libphonenumber-js/-/libphonenumber-js-1.10.37.tgz#185264130c9375f17d0c487a288223294579929c"
5376+
integrity sha512-Z10PCaOCiAxbUxLyR31DNeeNugSVP6iv/m7UrSKS5JHziEMApJtgku4e9Q69pzzSC9LnQiM09sqsGf2ticZnMw==
5377+
53795378
lines-and-columns@^1.1.6:
53805379
version "1.2.4"
53815380
resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632"
@@ -8081,7 +8080,7 @@ tsconfig-paths@^3.14.1, tsconfig-paths@^3.5.0, tsconfig-paths@^3.9.0:
80818080
minimist "^1.2.6"
80828081
strip-bom "^3.0.0"
80838082

8084-
[email protected], tslib@>=1.9.0, tslib@^2.1.0, tslib@^2.5.0:
8083+
[email protected], tslib@^2.1.0, tslib@^2.5.0:
80858084
version "2.5.0"
80868085
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.5.0.tgz#42bfed86f5787aeb41d031866c8f402429e0fddf"
80878086
integrity sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg==
@@ -8352,10 +8351,10 @@ validate-npm-package-license@^3.0.1:
83528351
spdx-correct "^3.0.0"
83538352
spdx-expression-parse "^3.0.0"
83548353

8355-
validator@13.0.0:
8356-
version "13.0.0"
8357-
resolved "https://registry.yarnpkg.com/validator/-/validator-13.0.0.tgz#0fb6c6bb5218ea23d368a8347e6d0f5a70e3bcab"
8358-
integrity sha512-anYx5fURbgF04lQV18nEQWZ/3wHGnxiKdG4aL8J+jEDsm98n/sU/bey+tYk6tnGJzm7ioh5FoqrAiQ6m03IgaA==
8354+
validator@^13.7.0:
8355+
version "13.9.0"
8356+
resolved "https://registry.yarnpkg.com/validator/-/validator-13.9.0.tgz#33e7b85b604f3bbce9bb1a05d5c3e22e1c2ff855"
8357+
integrity sha512-B+dGG8U3fdtM0/aNK4/X8CXq/EcxU2WPrPEkJGslb47qyHsxmbggTWK0yEA4qnYVNF+nxNlN88o14hIcPmSIEA==
83598358

83608359
vary@^1, vary@~1.1.2:
83618360
version "1.1.2"

0 commit comments

Comments
 (0)