Store: MobileRead plugin, Fix issue with searching with unicode characters.

This commit is contained in:
John Schember 2011-09-20 20:07:41 -04:00
parent beea6bcd11
commit 7fc7d7487c

View File

@ -44,9 +44,12 @@ class MobileReadStore(BasicStoreConfig, StorePlugin):
def search(self, query, max_results=10, timeout=60): def search(self, query, max_results=10, timeout=60):
books = self.get_book_list() books = self.get_book_list()
if not books:
return
sf = SearchFilter(books) sf = SearchFilter(books)
matches = sf.parse(query) matches = sf.parse(query.decode('utf-8', 'replace'))
for book in matches: for book in matches:
book.price = '$0.00' book.price = '$0.00'