Asp.Net-Core-Inventory-Order-Management-System icon indicating copy to clipboard operation
Asp.Net-Core-Inventory-Order-Management-System copied to clipboard

EmailService: Use proper display names in MailboxAddress

Open ZohaiAli opened this issue 6 months ago • 0 comments

Issue

In Infrastructure.EmailManager.EmailService, the MailboxAddress is currently used as:

message.From.Add(new MailboxAddress("noreply", _smtpSettings.UserName));
message.To.Add(new MailboxAddress(email, email));

Suggested Fix

If the recipient's name is available, use it as the display name: message.To.Add(new MailboxAddress(userName ?? email, email));

Similarly, the sender's display name can be more descriptive: message.From.Add(new MailboxAddress("NoReply - Indotalent", _smtpSettings.UserName));

ZohaiAli avatar Oct 15 '25 07:10 ZohaiAli