Nested properties of non-strict schema are undefined after reload #11309
Labels
confirmed-bug
We've confirmed this is a bug in Mongoose and will fix it.
priority
Automatically set for Mongoose Pro subscribers
Milestone
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Nested properties of a non-strict schema appear as undefined after a document is loaded from the database
If the current behavior is a bug, please provide the steps to reproduce.
What is the expected behavior?
To be able to log the nested property
foo
and see it's value after reloading the item from the database.Instead,
foo
is undefined.What are the versions of Node.js, Mongoose and MongoDB you are using? Note that "latest" is not a version.
Mongoose 6.1.10
MongoDB 5.0.3
Node 16.13.1
The text was updated successfully, but these errors were encountered: