using the same API for email UI and sending email
This commit is contained in:
@ -70,7 +70,15 @@ function normalizeEmailAddresses(to) {
|
||||
|
||||
return emails; // Always returns an array
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Final email sending function.
|
||||
/// </summary>
|
||||
/// <param name="to">Email address or array of email addresses</param>
|
||||
/// <param name="subject">Email subject</param>
|
||||
/// <param name="text">Plain text version of the email</param>
|
||||
/// <param name="html">HTML version of the email</param>
|
||||
/// <param name="attachments">Array of attachment objects</param>
|
||||
/// <returns>Promise</returns>
|
||||
|
||||
exports.SendEmail = async function (to, subject, text, html, attachments = []) {
|
||||
let sender = process.env.EMAIL_SENDER || '"Специално Свидетелстване София" <sofia@mwitnessing.com>';
|
||||
|
Reference in New Issue
Block a user