From 9b245bdcf508964136244cf2ae0a3d9bfb25fb9a Mon Sep 17 00:00:00 2001 From: John Schember Date: Sat, 28 May 2011 10:41:51 -0400 Subject: [PATCH] Store: ... --- src/calibre/customize/builtins.py | 2 +- src/calibre/gui2/store/ebookshoppe_uk_plugin.py | 11 +++++------ 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/calibre/customize/builtins.py b/src/calibre/customize/builtins.py index 0b83d0f45b..c57c19fd0b 100644 --- a/src/calibre/customize/builtins.py +++ b/src/calibre/customize/builtins.py @@ -1420,7 +1420,7 @@ plugins += [ StoreBeWriteStore, StoreDieselEbooksStore, StoreEbookscomStore, - #StoreEBookShoppeUKStore, + StoreEBookShoppeUKStore, StoreEPubBuyDEStore, StoreEHarlequinStore, StoreFeedbooksStore, diff --git a/src/calibre/gui2/store/ebookshoppe_uk_plugin.py b/src/calibre/gui2/store/ebookshoppe_uk_plugin.py index b45b0e99d5..afe4d6ccc5 100644 --- a/src/calibre/gui2/store/ebookshoppe_uk_plugin.py +++ b/src/calibre/gui2/store/ebookshoppe_uk_plugin.py @@ -62,18 +62,17 @@ class EBookShoppeUKStore(BasicStoreConfig, StorePlugin): s = SearchResult() s.cover_url = cover_url s.title = title.strip() - # Set the author to the query terms to ensure that author - # queries match something when pruning searches. Of course, this - # means that all books will match. Sigh... - s.author = query s.price = price s.drm = SearchResult.DRM_UNLOCKED s.detail_item = id - s.formats = '' + + self.my_get_details(s, timeout) + if not s.author: + continue yield s - def get_details(self, search_result, timeout): + def my_get_details(self, search_result, timeout): br = browser() with closing(br.open(search_result.detail_item, timeout=timeout)) as nf: idata = html.fromstring(nf.read())