From 590082709fb73dcbab7fc502dbe79fa536722983 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Mon, 5 May 2014 16:25:20 -0400 Subject: [PATCH] fixed #1488 - emails are processed 100 at a time --- src/user/jobs.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/user/jobs.js b/src/user/jobs.js index c2e88e752f..2655b96a67 100644 --- a/src/user/jobs.js +++ b/src/user/jobs.js @@ -59,7 +59,7 @@ module.exports = function(User) { }); // Consider using eachLimit, but *only* if people complain about email relays choking -- otherwise we're ok. - async.each(users, function(userObj, next) { + async.eachLimit(users, 100, function(userObj, next) { user.notifications.getDailyUnread(userObj.uid, function(err, notifications) { // Turn relative URLs into absolute ones for(var i=0; i