qmongo
v0.1.1
Published
Simple helper to use Q promises with Mongoose
Downloads
1
Readme
qm
Simple helper to use Q promises with Mongoose. It makes very simple to chain and combine promises (especially with Q.when)
Installation
Server side
$ npm install qmongo
Usage
var qmongo = require('qmongo');
var mongoose = require('mongoose');
[...]
var newUser = new User();
Q.when(
qmongo.exec(User.find({city: "Rome"}).limit(5)),
qmongo.save(newUser)
).then(function(args) {
console.log(args);
});
License
MIT