mongoose-autopopulate icon indicating copy to clipboard operation
mongoose-autopopulate copied to clipboard

Always populate() certain fields in your mongoose schemas

Results 17 mongoose-autopopulate issues
Sort by recently updated
recently updated
newest added

The pre hook is not working! and it doesn't populate the teacher field. `const mongoose = require('mongoose'); const assignmentSchema = new mongoose.Schema( { teacher: { type: mongoose.Schema.ObjectId, ref: 'User' },...

I am autopopulating a virtual field and the populated documents have a field with _refPath_. However the field with _refPath_ is not autopopulated. The same field is autopopulated if _refPath_...

This PR resolves issue #94 - `this.ownerDocument` inside of `post("save")` is always a function in latest versions of mongoose

Hi, I have noticed this issue where autopopulate suddenly stop working for array. if we restart node, it start populating. Schema is more less like example: var bandSchema = new...

Still has an issue where we can't modify `options` if user doesn't pass options, so we'll need to figure out how to fix that. Re: #79

insertMany method at mongoose like create many this plugin has to inject it's middleware at insertMany pre-post to populate on createMany https://mongoosejs.com/docs/api.html#model_Model.insertMany

I need to autopopulate from a GridFS schema but it is not working: ``` import * as mongoose from 'mongoose'; import { Schema } from 'mongoose'; import * as autopopulate...

selectPopulatedPaths not working with virtual prop

Hello ! First of all, thanks for mongoose & mongoose-autopopulate. I tried to reduce my example to its simplest form. I'm using Nestjs as backend framework. Reproduction schema is following:...

### How to disable auto populate when create. - I'm doing this to create a doc ```ts const result = await this.model.create(fields); debugger return result ``` - Then in `debugger`...