Update email code to send an email per EditUserCell
using multiple recipients is break of privacy since user will be able to see each other's emails.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import nodemailer, { SendMailOptions } from 'nodemailer'
|
||||
|
||||
interface Args {
|
||||
to: SendMailOptions['to']
|
||||
export interface SendMailArgs {
|
||||
to: string
|
||||
from: SendMailOptions['from']
|
||||
subject: string
|
||||
text: string
|
||||
@@ -26,7 +26,7 @@ export function sendMail({
|
||||
from,
|
||||
subject,
|
||||
text,
|
||||
}: Args): Promise<SuccessResult> {
|
||||
}: SendMailArgs): Promise<SuccessResult> {
|
||||
const transporter = nodemailer.createTransport({
|
||||
host: 'smtp.mailgun.org',
|
||||
port: 587,
|
||||
|
||||
Reference in New Issue
Block a user