Fix title, send out the remaining emails today

This commit is contained in:
Ian Philips 2022-10-04 08:55:44 -06:00
parent 6ac467764d
commit e6374c4994
2 changed files with 6 additions and 5 deletions

View File

@ -63,7 +63,7 @@ export const unsubscribe: EndpointDefinition = {
xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>Manifold Markets 7th Day Anniversary Gift!</title>
<title>Unsubscribe from Manifold Markets emails</title>
<!--[if !mso]><!-->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->
@ -216,7 +216,7 @@ export const unsubscribe: EndpointDefinition = {
xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>Manifold Markets 7th Day Anniversary Gift!</title>
<title>Unsubscribe from Manifold Markets emails</title>
<!--[if !mso]><!-->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->

View File

@ -17,8 +17,9 @@ import { filterDefined } from '../../common/util/array'
export const weeklyMarketsEmails = functions
.runWith({ secrets: ['MAILGUN_KEY'], memory: '4GB' })
// every minute on Monday for an hour at 12pm PT (UTC -07:00)
.pubsub.schedule('* 19 * * 1')
// TODO change back to Monday after the rest of the emails go out
// every minute on Tuesday for 2 hours starting at 12pm PT (UTC -07:00)
.pubsub.schedule('* 19-20 * * 2')
.timeZone('Etc/UTC')
.onRun(async () => {
await sendTrendingMarketsEmailsToAllUsers()
@ -53,7 +54,7 @@ async function sendTrendingMarketsEmailsToAllUsers() {
!user.weeklyTrendingEmailSent
)
})
.slice(150) // Send the emails out in batches
.slice(125) // Send the emails out in batches
log(
'Sending weekly trending emails to',
privateUsersToSendEmailsTo.length,