@tsed/platform-params 8.27.0 → 8.28.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { constant, injectable, injectMany } from "@tsed/di";
|
|
2
2
|
import { deserialize } from "@tsed/json-mapper";
|
|
3
|
-
import {
|
|
3
|
+
import { compile } from "@tsed/schema";
|
|
4
4
|
import { ParamTypes } from "../domain/ParamTypes.js";
|
|
5
5
|
import { RequiredValidationError } from "../errors/RequiredValidationError.js";
|
|
6
6
|
function cast(value, metadata) {
|
|
@@ -58,7 +58,7 @@ export class ValidationPipe {
|
|
|
58
58
|
if (value === undefined) {
|
|
59
59
|
return value;
|
|
60
60
|
}
|
|
61
|
-
const schema =
|
|
61
|
+
const schema = compile(metadata, {
|
|
62
62
|
customKeys: true
|
|
63
63
|
});
|
|
64
64
|
// TODO retrieve the right validator from metadata
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@tsed/platform-params",
|
|
3
3
|
"description": "Params module for Ts.ED Framework",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"version": "8.
|
|
5
|
+
"version": "8.28.0",
|
|
6
6
|
"source": "./src/index.ts",
|
|
7
7
|
"main": "./lib/esm/index.js",
|
|
8
8
|
"module": "./lib/esm/index.js",
|
|
@@ -26,13 +26,13 @@
|
|
|
26
26
|
"tslib": ">=2.7.0"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
|
-
"@tsed/barrels": "8.
|
|
30
|
-
"@tsed/core": "8.
|
|
31
|
-
"@tsed/di": "8.
|
|
32
|
-
"@tsed/exceptions": "8.
|
|
33
|
-
"@tsed/json-mapper": "8.
|
|
34
|
-
"@tsed/schema": "8.
|
|
35
|
-
"@tsed/typescript": "8.
|
|
29
|
+
"@tsed/barrels": "8.28.0",
|
|
30
|
+
"@tsed/core": "8.28.0",
|
|
31
|
+
"@tsed/di": "8.28.0",
|
|
32
|
+
"@tsed/exceptions": "8.28.0",
|
|
33
|
+
"@tsed/json-mapper": "8.28.0",
|
|
34
|
+
"@tsed/schema": "8.28.0",
|
|
35
|
+
"@tsed/typescript": "8.28.0",
|
|
36
36
|
"eslint": "9.12.0",
|
|
37
37
|
"typescript": "6.0.2",
|
|
38
38
|
"vitest": "4.1.4"
|