Split name env variable

This commit is contained in:
Ahmed Al-Taiar
2024-09-27 22:57:30 -04:00
parent 5c41588249
commit c9227cf9b9
7 changed files with 12 additions and 10 deletions

View File

@ -17,7 +17,7 @@ const transporter = nodemailer.createTransport({
export const sendEmail = async ({ to, subject, text, html }: Options) => {
return await transporter.sendMail({
from: `"${process.env.NAME} (noreply)" <${process.env.GMAIL}>`,
from: `"${process.env.FIRST_NAME} ${process.env.LAST_NAME} (noreply)" <${process.env.GMAIL}>`,
to: Array.isArray(to) ? to : [to],
subject,
text,