dimanche 6 juillet 2014

Variable and Mongoose


Vote count:

0




Would like a variable to receive the result of a 'find' and 'findOne' in mongoose, example:



var model = Model.find();
console.log(model);


Instead of this:



var model = Model.find(function (err, model) {
console.log(model);
});


As the Mongoid, of Ruby.



asked 48 secs ago






Aucun commentaire:

Enregistrer un commentaire