| Index: util.py
|
| diff --git a/util.py b/util.py
|
| index 85c768777960278d6d923fc132355616238bdbb4..3eb5934d9b193c7c5716a42c59e908821fbfc102 100644
|
| --- a/util.py
|
| +++ b/util.py
|
| @@ -86,3 +86,10 @@ def get_emails(string):
|
| [ 'test@example.com', 'committers@chromium.org' ]
|
| """
|
| return [entry[1] for entry in email.utils.getaddresses([string])]
|
| +
|
| +
|
| +def canonicalize_email(address):
|
| + """Takes an email address and returns its canonicalized form."""
|
| + emails = get_emails(address)
|
| + assert len(emails) == 1
|
| + return emails[0]
|
|
|