mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix #822359 (AttributeError:'OpenBooksStore' object has no attribute 'url' Traceback (most recent call last): File "/usr/lib/calibre/calibre/gui2/actions/store.py", line 126, in open_store store_plugin.open(self.gui) File "/usr/lib/calibre/calibre/gui2/store/stores/open_books_plugin.py", line 31, in open d = WebStoreDialog(self.gui, self.url, parent, detail_item) AttributeError: 'OpenBooksStore' object has no attribute 'url' [with fix])
This commit is contained in:
parent
6b7d51e282
commit
8408f0119f
@ -28,7 +28,7 @@ class OpenBooksStore(BasicStoreConfig, StorePlugin):
|
|||||||
if external or self.config.get('open_external', False):
|
if external or self.config.get('open_external', False):
|
||||||
open_url(QUrl(url_slash_cleaner(detail_item if detail_item else url)))
|
open_url(QUrl(url_slash_cleaner(detail_item if detail_item else url)))
|
||||||
else:
|
else:
|
||||||
d = WebStoreDialog(self.gui, self.url, parent, detail_item)
|
d = WebStoreDialog(self.gui, url, parent, detail_item)
|
||||||
d.setWindowTitle(self.name)
|
d.setWindowTitle(self.name)
|
||||||
d.set_tags(self.config.get('tags', ''))
|
d.set_tags(self.config.get('tags', ''))
|
||||||
d.exec_()
|
d.exec_()
|
||||||
@ -44,7 +44,7 @@ class OpenBooksStore(BasicStoreConfig, StorePlugin):
|
|||||||
for data in doc.xpath('//ul[@id="object_list"]//li'):
|
for data in doc.xpath('//ul[@id="object_list"]//li'):
|
||||||
if counter <= 0:
|
if counter <= 0:
|
||||||
break
|
break
|
||||||
|
|
||||||
id = ''.join(data.xpath('.//div[@class="links"]/a[1]/@href'))
|
id = ''.join(data.xpath('.//div[@class="links"]/a[1]/@href'))
|
||||||
id = id.strip()
|
id = id.strip()
|
||||||
if not id:
|
if not id:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user