Add userId to email template so users can unsubscribe

This commit is contained in:
jahooma 2022-01-19 12:43:12 -06:00
parent b3282c4302
commit 5ce23c0bdb

View File

@ -4,6 +4,7 @@ import { sendTemplateEmail } from './send-email'
import { getPrivateUser, getUser } from './utils' import { getPrivateUser, getUser } from './utils'
type market_resolved_template = { type market_resolved_template = {
userId: string
name: string name: string
creatorName: string creatorName: string
question: string question: string
@ -35,6 +36,7 @@ export const sendMarketResolutionEmail = async (
const subject = `Resolved ${outcome}: ${contract.question}` const subject = `Resolved ${outcome}: ${contract.question}`
const templateData: market_resolved_template = { const templateData: market_resolved_template = {
userId: user.id,
name: user.name, name: user.name,
creatorName: creator.name, creatorName: creator.name,
question: contract.question, question: contract.question,