diff options
author | Jefferson Stachelski <jstachel@thoughtworks.com> | 2015-11-20 18:22:57 -0200 |
---|---|---|
committer | Jefferson Stachelski <jstachel@thoughtworks.com> | 2015-11-24 15:37:39 -0200 |
commit | 2c477f6045bd840d5794d6caff001ad8bdd8b760 (patch) | |
tree | 170a308cf1ace1cd2d21adab9c99c6af21d752e9 | |
parent | 760ce63ad060a7396d1d97ba428170eb43852797 (diff) |
Issue #536 - Refactoed search_addresses
-rw-r--r-- | service/pixelated/adapter/search/contacts.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/service/pixelated/adapter/search/contacts.py b/service/pixelated/adapter/search/contacts.py index f1ea2575..733489b0 100644 --- a/service/pixelated/adapter/search/contacts.py +++ b/service/pixelated/adapter/search/contacts.py @@ -44,10 +44,9 @@ def search_addresses(searcher, query): results = [] for field in ['to', 'cc', 'bcc', 'sender']: query_parser = QueryParser(field, searcher.schema) - query_parsed = query_parser.parse("*%s* OR *%s*" % (query.title(), query)) results.append( searcher.search( - query_parsed, + query_parser.parse("*%s* OR *%s*" % (query.title(), query)), limit=None, mask=restrict_q, groupedby=sorting.FieldFacet( |