From 86dff92179bacb014aca00a3de5b5a0e452d911b Mon Sep 17 00:00:00 2001 From: Slendy Date: Mon, 2 Jan 2023 06:26:30 -0600 Subject: [PATCH] Specify host and port for SmtpClient --- ProjectLighthouse/Helpers/SMTPHelper.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ProjectLighthouse/Helpers/SMTPHelper.cs b/ProjectLighthouse/Helpers/SMTPHelper.cs index 92ce601d..e3dc8146 100644 --- a/ProjectLighthouse/Helpers/SMTPHelper.cs +++ b/ProjectLighthouse/Helpers/SMTPHelper.cs @@ -43,7 +43,7 @@ public class SMTPHelper try { - using SmtpClient client = new() + using SmtpClient client = new(ServerConfiguration.Instance.Mail.Host, ServerConfiguration.Instance.Mail.Port) { EnableSsl = ServerConfiguration.Instance.Mail.UseSSL, Credentials = new NetworkCredential(ServerConfiguration.Instance.Mail.Username, ServerConfiguration.Instance.Mail.Password),