Type error if an object with type 'any' is passed to the model's create method (Typescript) #11970
Closed
2 tasks done
Labels
typescript
Types or Types-test related issue / Pull Request
Milestone
Prerequisites
Mongoose version
6.4.0
Node.js version
16.15.0
MongoDB server version
5.x
Description
The 'create' method returns wrong object type if the prototype passed to it is of type 'any'
Steps to Reproduce
A code snippet to reproduce.
Workaround
// @ts-ignore
Expected Behavior
A correct type must be returned.
The text was updated successfully, but these errors were encountered: