public override IEmailRecipients GetRecipients() { return(new EmailRecipients( to: AccountToSendTo.EmailAllowed ? new[] { AccountToSendTo.ToMailAddress() } : new MailAddress[0], replyTo: new[] { AccountToReplyTo.ToMailAddress() })); }
public override IEmailRecipients GetRecipients() { if (!AccountToSendTo.EmailAllowed) { return(EmailRecipients.None); } return(new EmailRecipients( to: new[] { AccountToSendTo.ToMailAddress() }, replyTo: new[] { AccountToReplyTo.ToMailAddress() })); }