Example #1
0
        public string[] GetDistinctEmails()
        {
            var list = new List <string>();

            if (To != null && To.Count() > 0)
            {
                list.AddRange(To);
            }

            if (Cc != null && Cc.Count() > 0)
            {
                list.AddRange(Cc);
            }

            if (Bcc != null && Bcc.Count() > 0)
            {
                list.AddRange(Bcc);
            }

            var result = list.Distinct().ToArray();

            return(result);
        }