diff --git a/services/web/app/src/Features/User/UserOnboardingController.js b/services/web/app/src/Features/User/UserOnboardingController.js index 4fd1245a1f..1f72464791 100644 --- a/services/web/app/src/Features/User/UserOnboardingController.js +++ b/services/web/app/src/Features/User/UserOnboardingController.js @@ -7,6 +7,8 @@ const _ = require('underscore') module.exports = { sendRecentSignupOnboardingEmails(req, res, next) { + res.setTimeout(600 * 1000) // increase timeout to handle days with a lot of signups + // find all the users with no onboardingEmailSentAt and // have signed up in the last 7 days db.users.find( diff --git a/services/web/test/unit/src/User/UserOnboardingControllerTests.js b/services/web/test/unit/src/User/UserOnboardingControllerTests.js index 89ad150694..ed6da3348f 100644 --- a/services/web/test/unit/src/User/UserOnboardingControllerTests.js +++ b/services/web/test/unit/src/User/UserOnboardingControllerTests.js @@ -47,7 +47,9 @@ describe('UserOnboardingController', function() { } }) this.req = {} - this.res = {} + this.res = { + setTimeout: sinon.stub() + } }) it('sends onboarding emails', function(done) {