From d77670fb7023aae86b7039684a6b059ee91bf17d Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Tue, 2 Mar 2021 17:22:08 +0100 Subject: [PATCH] Updated comments --- src/Mailer.ts | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/Mailer.ts b/src/Mailer.ts index 3573dcc..6069467 100644 --- a/src/Mailer.ts +++ b/src/Mailer.ts @@ -11,11 +11,10 @@ import { MailServerConfigError } from './errors/MailErrors'; /** - * This class is responsible for all things pdf creation. - * This uses the html templates from src/templates. + * This class is responsible for all mail sending. + * This uses the html and plaintext templates from src/templates. */ export class Mailer { - private templateDir = path.join(__dirname, '/templates'); private transport: Mail; private static interpolations = { copyright_owner: config.copyright_owner } @@ -63,7 +62,7 @@ export class Mailer { } /** - * Function for sending a test mail from the test mail template. + * Function for sending a reset mail from the reset mail template. * @param to_address The address the mail will be sent to. Should always get pulled from a user object. * @param token The requested password reset token - will be combined with the app_url to generate a password reset link. */ @@ -87,8 +86,7 @@ export class Mailer { /** * Function for sending a test mail from the test mail template. - * @param to_address The address the mail will be sent to. Should always get pulled from a user object. - * @param token The requested password reset token - will be combined with the app_url to generate a password reset link. + * @param to_address The address the mail will be sent to - usually the FROM address. */ public async sendTestMail(to_address: string = config.mail_from, locale: string = "en") { await i18next.changeLanguage(locale);