Fix deprecation

This commit is contained in:
Raymond Feng 2015-01-30 11:34:46 -08:00
parent ec4000745a
commit 60938c245a
1 changed files with 2 additions and 2 deletions

View File

@ -134,12 +134,12 @@ exports.download = function (provider, req, res, container, file, cb) {
reader.on('error', function (err) {
if (err.code === 'ENOENT') {
res.type('application/json');
res.send(404, { error: err });
res.status(404).send({ error: err });
return;
}
res.type('application/json');
res.send(500, { error: err });
res.status(500).send({ error: err });
});
}