diff --git a/Streetwriters.Common/Clients.cs b/Streetwriters.Common/Clients.cs index de31bc7..7b5049d 100644 --- a/Streetwriters.Common/Clients.cs +++ b/Streetwriters.Common/Clients.cs @@ -34,7 +34,7 @@ namespace Streetwriters.Common Id = "notesnook", Name = "Notesnook", SenderEmail = Constants.NOTESNOOK_SENDER_EMAIL, - SenderName = Constants.NOTESNOOK_SENDER_NAME, + SenderName = "Notesnook", Type = ApplicationType.NOTESNOOK, AppId = ApplicationType.NOTESNOOK, AccountRecoveryRedirectURL = $"{Constants.NOTESNOOK_APP_HOST}/account/recovery", diff --git a/Streetwriters.Common/Constants.cs b/Streetwriters.Common/Constants.cs index 4cf1bb4..5410ce4 100644 --- a/Streetwriters.Common/Constants.cs +++ b/Streetwriters.Common/Constants.cs @@ -41,10 +41,8 @@ namespace Streetwriters.Common public static string SMTP_PASSWORD => Environment.GetEnvironmentVariable("SMTP_PASSWORD"); public static string SMTP_HOST => Environment.GetEnvironmentVariable("SMTP_HOST"); public static string SMTP_PORT => Environment.GetEnvironmentVariable("SMTP_PORT"); - public static string SMTP_REPLYTO_NAME => Environment.GetEnvironmentVariable("SMTP_REPLYTO_NAME"); public static string SMTP_REPLYTO_EMAIL => Environment.GetEnvironmentVariable("SMTP_REPLYTO_EMAIL"); public static string NOTESNOOK_SENDER_EMAIL => Environment.GetEnvironmentVariable("NOTESNOOK_SENDER_EMAIL"); - public static string NOTESNOOK_SENDER_NAME => Environment.GetEnvironmentVariable("NOTESNOOK_SENDER_NAME"); public static string NOTESNOOK_APP_HOST => Environment.GetEnvironmentVariable("NOTESNOOK_APP_HOST"); public static string NOTESNOOK_API_SECRET => Environment.GetEnvironmentVariable("NOTESNOOK_API_SECRET"); diff --git a/Streetwriters.Identity/Services/EmailSender.cs b/Streetwriters.Identity/Services/EmailSender.cs index c255a0b..eacdca2 100644 --- a/Streetwriters.Identity/Services/EmailSender.cs +++ b/Streetwriters.Identity/Services/EmailSender.cs @@ -196,8 +196,8 @@ namespace Streetwriters.Identity.Services message.To.Add(new MailboxAddress("", email)); message.Subject = await Template.Parse(template.Subject).RenderAsync(template.Data); - if (!string.IsNullOrEmpty(Constants.SMTP_REPLYTO_NAME) && !string.IsNullOrEmpty(Constants.SMTP_REPLYTO_EMAIL)) - message.ReplyTo.Add(new MailboxAddress(Constants.SMTP_REPLYTO_NAME, Constants.SMTP_REPLYTO_EMAIL)); + if (!string.IsNullOrEmpty(Constants.SMTP_REPLYTO_EMAIL)) + message.ReplyTo.Add(MailboxAddress.Parse(Constants.SMTP_REPLYTO_EMAIL)); message.Body = await GetEmailBodyAsync(template, client, sender); diff --git a/Streetwriters.Identity/Services/SMSSender.cs b/Streetwriters.Identity/Services/SMSSender.cs index 6fd1887..fa13853 100644 --- a/Streetwriters.Identity/Services/SMSSender.cs +++ b/Streetwriters.Identity/Services/SMSSender.cs @@ -19,21 +19,15 @@ along with this program. If not, see . using Streetwriters.Identity.Interfaces; using Streetwriters.Common.Interfaces; -using MessageBird; -using MessageBird.Objects; -using Microsoft.Extensions.Options; -using Streetwriters.Identity.Models; using Streetwriters.Common; using Twilio.Rest.Verify.V2.Service; using Twilio; using System.Threading.Tasks; -using System; namespace Streetwriters.Identity.Services { public class SMSSender : ISMSSender { - private Client client; public SMSSender() { if (!string.IsNullOrEmpty(Constants.TWILIO_ACCOUNT_SID) && !string.IsNullOrEmpty(Constants.TWILIO_AUTH_TOKEN))