Skip to content

Node.js based forum software built for the modern web

added err to callbacks

Baris Usakli55d008d71ffe
diff --git a/src/categories.js b/src/categories.js
index 2cfb7f8160..bfdd51435f 100644
--- a/src/categories.js
+++ b/src/categories.js
@@ -220,11 +220,11 @@ var db = require('./database.js'),
if (err) {
winston.err(err);
- return callback([]);
+ return callback(err, []);
}
if (pids.length === 0) {
- return callback([]);
+ return callback(null, []);
}
posts.getPostSummaryByPids(pids, true, function(err, postData) {