-
-
Notifications
You must be signed in to change notification settings - Fork 612
Closed
Description
Describe the bug
This is a follow-up to #6076 (sorry again for the first failed reproduction test case!)
This regression was introduced in v6.3.11 and probably linked to 55df57f (#6050).
When persisting a date inside a JSON property with the MongoDB driver, it is correctly saved as an ISODate.
When retrieving the document, the MongoDB driver returns an ISODates object (BSON date), but MikroORM hydration erases its content and prototype. The date is instead hydrated as an empty object {}.
Reproduction
Here is a test case: https://github.com/alexandre-abrioux/mikro-orm-issues/blob/iss-6078/src/example.test.ts
What driver are you using?
@mikro-orm/mongodb
MikroORM version
6.3.11
Node.js version
22.4.0
Operating system
No response
Validations
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord.
- The provided reproduction is a minimal reproducible example of the bug.
Metadata
Metadata
Assignees
Labels
No labels