gotto check read after each pass

v1.18.x
barisusakli 11 years ago
parent e097ac1fa7
commit a9ca035e1e

@ -49,6 +49,10 @@ module.exports = function(Topics) {
return !read[index]; return !read[index];
}); });
privileges.topics.filter('read', newtids, uid, function(err, newtids) {
if (err) {
return next(err);
}
unreadTids.push.apply(unreadTids, newtids); unreadTids.push.apply(unreadTids, newtids);
start = stop + 1; start = stop + 1;
@ -57,11 +61,9 @@ module.exports = function(Topics) {
next(); next();
}); });
}); });
});
}, function(err) { }, function(err) {
if (err) { callback(err, unreadTids);
return callback(err);
}
privileges.topics.filter('read', unreadTids, uid, callback);
}); });
}; };

Loading…
Cancel
Save