Skip to content

Commit

Permalink
Merge pull request #624 from adaptlearning/fix-for-callback-null
Browse files Browse the repository at this point in the history
Fix for "callback is not a function" error
  • Loading branch information
brian-learningpool committed Apr 7, 2015
2 parents be21f7e + 4acbe1c commit e9db6ed
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion routes/download/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,10 @@ server.get('/download/:tenant/:course/:title/download.zip', function (req, res,

fs.stat(downloadZipFilename, function(err, stat) {
if (err) {
callback(err, 'Error calling fs.stat');
logger.log('error', 'Error calling fs.stat');
logger.log('error', error);

next(err);
} else {
res.writeHead(200, {
'Content-Type': 'application/zip',
Expand Down

0 comments on commit e9db6ed

Please sign in to comment.