-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Closed
Labels
needs triageThis issue has not been looked intoThis issue has not been looked into
Description
Is there an existing issue for this?
- I have searched the existing issues
Current behavior
As shown in the docs or explained in the source, the skipNullProperties options should be used to skip the validation for nullable values. I assume the value was added by accident to the Validator Options Interface? It does not exist for class-validator and seems to be only available in nestjs' mapped-types
Minimum reproduction code
https://codesandbox.io/p/devbox/5jyyll
Steps to reproduce
Run the "start" script in the code sandbox. It should print the following:
Expected behavior
I'd expected the skipNullProperties setting to be a global switch to set the value for all PartialTypes to the globally set value.
Package
- I don't know. Or some 3rd-party package
-
@nestjs/common -
@nestjs/core -
@nestjs/microservices -
@nestjs/platform-express -
@nestjs/platform-fastify -
@nestjs/platform-socket.io -
@nestjs/platform-ws -
@nestjs/testing -
@nestjs/websockets - Other (see below)
Other package
@nestjs/mapped-types
NestJS version
11.0.12
Packages versions
mappedTypes => 2.0.1
common => 11.0.12
Node.js version
v20.11.0
In which operating systems have you tested?
- macOS
- Windows
- Linux
Other
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
needs triageThis issue has not been looked intoThis issue has not been looked into
