mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix #5129 (The author of the metadata download plugins goes wrong after downloaded metadata for a book)
This commit is contained in:
parent
5e2a1b3f81
commit
2ba5222c04
@ -39,7 +39,7 @@ class MetadataSource(Plugin):
|
|||||||
self.worker.daemon = True
|
self.worker.daemon = True
|
||||||
self.title = title
|
self.title = title
|
||||||
self.verbose = verbose
|
self.verbose = verbose
|
||||||
self.author = author
|
self.book_author = author
|
||||||
self.publisher = publisher
|
self.publisher = publisher
|
||||||
self.isbn = isbn
|
self.isbn = isbn
|
||||||
self.log = log if log is not None else default_log
|
self.log = log if log is not None else default_log
|
||||||
@ -139,7 +139,7 @@ class GoogleBooks(MetadataSource):
|
|||||||
def fetch(self):
|
def fetch(self):
|
||||||
from calibre.ebooks.metadata.google_books import search
|
from calibre.ebooks.metadata.google_books import search
|
||||||
try:
|
try:
|
||||||
self.results = search(self.title, self.author, self.publisher,
|
self.results = search(self.title, self.book_author, self.publisher,
|
||||||
self.isbn, max_results=10,
|
self.isbn, max_results=10,
|
||||||
verbose=self.verbose)
|
verbose=self.verbose)
|
||||||
except Exception, e:
|
except Exception, e:
|
||||||
@ -162,8 +162,8 @@ class ISBNDB(MetadataSource):
|
|||||||
else:
|
else:
|
||||||
if self.title:
|
if self.title:
|
||||||
args.extend(['--title', self.title])
|
args.extend(['--title', self.title])
|
||||||
if self.author:
|
if self.book_author:
|
||||||
args.extend(['--author', self.author])
|
args.extend(['--author', self.book_author])
|
||||||
if self.publisher:
|
if self.publisher:
|
||||||
args.extend(['--publisher', self.publisher])
|
args.extend(['--publisher', self.publisher])
|
||||||
if self.verbose:
|
if self.verbose:
|
||||||
@ -193,7 +193,7 @@ class Amazon(MetadataSource):
|
|||||||
return
|
return
|
||||||
from calibre.ebooks.metadata.amazon import get_social_metadata
|
from calibre.ebooks.metadata.amazon import get_social_metadata
|
||||||
try:
|
try:
|
||||||
self.results = get_social_metadata(self.title, self.author,
|
self.results = get_social_metadata(self.title, self.book_author,
|
||||||
self.publisher, self.isbn)
|
self.publisher, self.isbn)
|
||||||
except Exception, e:
|
except Exception, e:
|
||||||
self.exception = e
|
self.exception = e
|
||||||
|
Loading…
x
Reference in New Issue
Block a user