diff options
Diffstat (limited to 'alot/addressbook/__init__.py')
-rw-r--r-- | alot/addressbook/__init__.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/alot/addressbook/__init__.py b/alot/addressbook/__init__.py index 17800b33..28c4ecc7 100644 --- a/alot/addressbook/__init__.py +++ b/alot/addressbook/__init__.py @@ -34,7 +34,7 @@ class AddressBook(object): def lookup(self, query=''): """looks up all contacts where name or address match query""" res = [] - query = re.compile('.*%s.*' % query, self.reflags) + query = re.compile('.*%s.*' % re.escape(query), self.reflags) for name, email in self.get_contacts(): if query.match(name) or query.match(email): res.append((name, email)) |