Merge pull request #4482 from omnivore-app/jacksonh/email-logging
Add more logging to email sends
This commit is contained in:
@ -24,6 +24,7 @@ export type SendEmailJobData = Merge<
|
||||
>
|
||||
|
||||
export const sendEmailJob = async (data: SendEmailJobData) => {
|
||||
logger.info('sending email job:', { data })
|
||||
if (!data.to) {
|
||||
const user = await findActiveUser(data.userId)
|
||||
if (!user) {
|
||||
|
||||
@ -144,6 +144,12 @@ export const sendExportJobEmail = async (
|
||||
throw new Error('Invalid state')
|
||||
}
|
||||
|
||||
logger.info('enqueing email job:', {
|
||||
userId,
|
||||
subject,
|
||||
html,
|
||||
})
|
||||
|
||||
return enqueueSendEmail({
|
||||
userId,
|
||||
subject,
|
||||
|
||||
Reference in New Issue
Block a user