I'm using skipper gridfs to upload a picture in my sails app,here is my function:
upload: (req, res) => {
req.file('avatar')
.upload({
adapter: require('skipper-gridfs'),
uri: 'mongodb://127.0.0.1/27017/linucLab',
maxBytes: 1000000
}, function whenDone(err, uploadedFiles) {
if (err) return res.serverError(err);
else return res.json({
files: uploadedFiles,
textParams: req.allParams()
});
});
}
I get this error
MongoError: Can't get executor for query { files_id: ObjectId('591b702ad01d3aa826d545ba'), n: { $gte: 0 } }
via linux
No comments:
Post a Comment