Merge pull request #3043 from overleaf/hb-increase-timeout-on-onboarding-email

Increase timeout on user onboarding email endpoint

GitOrigin-RevId: d7c9aaae407e31ae2e9cfea5a6dce853c2737ab9
This commit is contained in:
Jakob Ackermann 2020-07-24 10:55:55 +02:00 committed by Copybot
parent d5472b8743
commit 9d8e20d3d8
2 changed files with 5 additions and 1 deletions

View file

@ -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(

View file

@ -47,7 +47,9 @@ describe('UserOnboardingController', function() {
}
})
this.req = {}
this.res = {}
this.res = {
setTimeout: sinon.stub()
}
})
it('sends onboarding emails', function(done) {