v1.18.x
barisusakli 10 years ago
parent ca87bc1577
commit 121de11400

@ -28,7 +28,7 @@ module.exports = function(User) {
return winston.log('[user/jobs] Did not send daily digests because subscription system is disabled.'); return winston.log('[user/jobs] Did not send daily digests because subscription system is disabled.');
} }
topics.getLatestTopics(0, 0, 10, 'day', function(err, topics) { topics.getLatestTopics(0, 0, 10, 'day', function(err, data) {
if (err) { if (err) {
return winston.error('[user/jobs] Could not send daily digests: ' + err.message); return winston.error('[user/jobs] Could not send daily digests: ' + err.message);
} }
@ -49,7 +49,7 @@ module.exports = function(User) {
return next(); return next();
} }
sendEmails(subscribed, topics, next); sendEmails(subscribed, data.topics, next);
}); });
}, function(err) { }, function(err) {
if (err) { if (err) {

Loading…
Cancel
Save