chore: move notification test, other refactoring (#111)

This commit is contained in:
Jef LeCompte
2020-09-20 13:18:32 -04:00
committed by GitHub
parent a3fc07daf0
commit 2a1f15041e
13 changed files with 40 additions and 32 deletions
+3 -3
View File
@@ -20,15 +20,15 @@ const mailOptions: Mail.Options = {
subject
};
export function sendEmail(text: string) {
mailOptions.text = text;
export function sendEmail(cartUrl: string) {
mailOptions.text = cartUrl;
transporter.sendMail(mailOptions, (error, info) => {
if (error) {
Logger.error(error);
} else {
// eslint-disable-next-line @typescript-eslint/restrict-template-expressions
Logger.info(` email sent: ${info.response}`);
Logger.info(` email sent: ${info.response}`);
}
});
}