import { EMAIL_TEMPLATE_ID } from 'common/enums' ; import { environment } from 'common/environment' ; import { notificationQueue } from 'connectors/queue/notification' ; import { LANGUAGES } from 'definitions' ; import { trans } from './utils' ; export const sendRegisterSuccess = async ( { to , recipient , language = 'zh_hant' , } ) => { const templateId = EMAIL_TEMPLATE_ID . registerSuccess [ language ] ; notificationQueue . sendMail ( { from : environment . emailFromAsk as string , templateId , personalizations : [ { to , dynamic_template_data : { subject : trans . registerSuccess ( language , { } ) , siteDomain : environment . siteDomain , recipient , } , } , ] , } ) ; } ;