add STMP_SECURE and changed auth config (#81)

* add STMP_SECURE and changed auth config
* relocated logic to mail.provider.ts
This commit is contained in:
olivierIllogika
2024-07-19 07:54:55 -04:00
committed by GitHub
parent a2ae341934
commit 227ac30d5e
2 changed files with 16 additions and 4 deletions

View File

@ -87,6 +87,13 @@ export class EnvironmentService {
return parseInt(this.configService.get<string>('SMTP_PORT'));
}
getSmtpSecure(): boolean {
const secure = this.configService
.get<string>('SMTP_SECURE', 'false')
.toLowerCase();
return secure === 'true';
}
getSmtpUsername(): string {
return this.configService.get<string>('SMTP_USERNAME');
}