You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched existing issues to ensure the bug has not already been reported
Mongoose version
8.7.0
Node.js version
18.x
MongoDB server version
7.0.12
Typescript version (if applicable)
^5.1.6
Description
After insertMany calling find with on an ObjectId parameter, it will fail to return any rows.
The issue happens when I have both a property of type: [Schema.Types.Mixed] and toObject: { flattenObjectIds: true }
I'm not sure why, but I've done written a jest test to show.
Prerequisites
Mongoose version
8.7.0
Node.js version
18.x
MongoDB server version
7.0.12
Typescript version (if applicable)
^5.1.6
Description
After
insertMany
callingfind
with on an ObjectId parameter, it will fail to return any rows.The issue happens when I have both a property of
type: [Schema.Types.Mixed]
andtoObject: { flattenObjectIds: true }
I'm not sure why, but I've done written a jest test to show.
Steps to Reproduce
Expected Behavior
Second test should pass
The text was updated successfully, but these errors were encountered: