summaryrefslogtreecommitdiff
path: root/alot/addressbook
diff options
context:
space:
mode:
authorLucas Hoffmann <l-m-h@web.de>2017-06-08 16:09:24 +0200
committerLucas Hoffmann <l-m-h@web.de>2017-06-08 16:19:05 +0200
commitc22802fc6a7cdd5643d55a89f38b95d149fd2650 (patch)
tree3dd347db8cedd539e17a26834e4f0c109514b96e /alot/addressbook
parent1c72a19d59c24a5621180118b779de22d2e9ea34 (diff)
Correct membership test
Diffstat (limited to 'alot/addressbook')
-rw-r--r--alot/addressbook/external.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/alot/addressbook/external.py b/alot/addressbook/external.py
index 6a89dd15..9de86f36 100644
--- a/alot/addressbook/external.py
+++ b/alot/addressbook/external.py
@@ -68,7 +68,7 @@ class ExternalAddressbook(AddressBook):
m = re.match(self.regex, l, self.reflags)
if m:
info = m.groupdict()
- if 'email' and 'name' in info:
+ if 'email' in info and 'name' in info:
email = info['email'].strip()
name = info['name']
res.append((name, email))