Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: include virtuals in document array toString() output if toObject.virtuals set #14335

Merged
merged 2 commits into from Feb 8, 2024

Conversation

vkarpov15
Copy link
Collaborator

Fix #14315

Summary

Right now document arrays' toString() function never includes virtuals in output, even if toObject.virtuals is set. This PR makes it so that we 1) bubble toObject and toJSON, minus transform, to implicitly created schemas, 2) don't hard-code virtuals: false when calling inspect() on subdocuments.

Examples

@vkarpov15 vkarpov15 added this to the 8.1.2 milestone Feb 8, 2024
@vkarpov15 vkarpov15 merged commit 6579f93 into master Feb 8, 2024
20 checks passed
@hasezoey hasezoey deleted the vkarpov15/gh-14315 branch February 8, 2024 17:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Populate Virtuals fails when localField is inside array (with reproduction code and data)
2 participants