These are chat archives for Automattic/mongoose

22nd
Dec 2018
Olivier Rudy
@rdy23x
Dec 22 2018 02:54
hello can you help me please ? my mongoose return null
var fin = conversation.find({ participansIds: req.params.id })
fin.populate('participansIds').exec((err,resul) => {
res.status(200).json(resul)
   })
var ConvSchema = new Schema({
participansIds: [{ type: Schema.Types.ObjectId, ref: 'Users' }],
groupeName:String
}, {
timestamps: true
});
this is my code