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

Add method to get all populated docs on a document #9702

Closed
vkarpov15 opened this issue Dec 13, 2020 · 1 comment
Closed

Add method to get all populated docs on a document #9702

vkarpov15 opened this issue Dec 13, 2020 · 1 comment
Assignees
Labels
new feature This change adds new functionality, like a new method or class
Milestone

Comments

@vkarpov15
Copy link
Collaborator

Re: #8115 . doc.getPopulatedDocs() should return an array of all populated documents associated with this doc.

const doc = await Story.findOne({ title: 'Casino Royale' }).populate('fans');
console.log(doc.getPopulatedDocs()); // List of all `fans` documents
@vkarpov15 vkarpov15 added the new feature This change adds new functionality, like a new method or class label Dec 13, 2020
@vkarpov15 vkarpov15 added this to the 5.12 milestone Dec 13, 2020
vkarpov15 added a commit that referenced this issue Jan 9, 2021
feat: implemented getPopulatedDocs()
This was referenced Mar 11, 2021
This was referenced Mar 13, 2021
@AlexRMU
Copy link

AlexRMU commented May 14, 2022

$getPopulatedDocs is in the code and types, but not in the documentation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature This change adds new functionality, like a new method or class
Projects
None yet
Development

No branches or pull requests

3 participants