callback to stop further processing in async.series

fix-export-regressions
webzwo0i 2016-02-15 04:00:25 +01:00
parent bf92ba0f9d
commit 4e21c16794
1 changed files with 3 additions and 5 deletions

View File

@ -79,8 +79,7 @@ exports.doExport = function(req, res, padId, type)
exporttxt.getPadTXTDocument(padId, req.params.rev, false, function(err, txt)
{
if (err) {
res.status(400);
res.send();
res.status(400).send();
console.warn("Could not process export request:",err.message);
} else {
res.send(txt);
@ -100,10 +99,9 @@ exports.doExport = function(req, res, padId, type)
exporthtml.getPadHTMLDocument(padId, req.params.rev, false, function(err, _html)
{
if (err) {
res.status(400);
res.send();
res.status(400).send();
console.warn("Could not process export request:",err.message);
return;
return callback("stop");
}
html = _html;
callback();