Skip to content

Commit

Permalink
Exscript.util.mail: sort receipient list, and remove duplicate receip…
Browse files Browse the repository at this point in the history
…ients
  • Loading branch information
knipknap committed Sep 11, 2017
1 parent b98c36e commit e60358e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Exscript/util/mail.py
Expand Up @@ -104,7 +104,7 @@ def _cleanup_mail_addresses(receipients):
if isinstance(receipients, list):
receipients = ','.join(receipients)
rcpt = re.split(r'\s*[,;\r\n]\s*', receipients.lower())
return [str(r) for r in rcpt if r.strip()]
return [str(r) for r in sorted(set(rcpt)) if r.strip()]

#
# Public.
Expand Down

0 comments on commit e60358e

Please sign in to comment.