mirror of
https://github.com/kovidgoyal/calibre.git
synced 2026-05-27 09:12:34 -04:00
Generator erroneously used as list
This commit is contained in:
@@ -1072,8 +1072,8 @@ class Amazon(Source):
|
||||
q['field-title'] = ' '.join(title_tokens)
|
||||
terms.extend(title_tokens)
|
||||
if authors:
|
||||
author_tokens = self.get_author_tokens(authors,
|
||||
only_first_author=True)
|
||||
author_tokens = list(self.get_author_tokens(authors,
|
||||
only_first_author=True))
|
||||
if author_tokens:
|
||||
q['field-author'] = ' '.join(author_tokens)
|
||||
terms.extend(author_tokens)
|
||||
|
||||
@@ -196,8 +196,8 @@ class Douban(Source):
|
||||
title_tokens = list(self.get_title_tokens(title))
|
||||
if title_tokens:
|
||||
q += build_term('title', title_tokens)
|
||||
author_tokens = self.get_author_tokens(authors,
|
||||
only_first_author=True)
|
||||
author_tokens = list(self.get_author_tokens(authors,
|
||||
only_first_author=True))
|
||||
if author_tokens:
|
||||
q += ((' ' if q != '' else '') +
|
||||
build_term('author', author_tokens))
|
||||
|
||||
@@ -210,7 +210,7 @@ class GoogleBooks(Source):
|
||||
title_tokens = list(self.get_title_tokens(title))
|
||||
if title_tokens:
|
||||
q += build_term('title', title_tokens)
|
||||
author_tokens = self.get_author_tokens(authors, only_first_author=True)
|
||||
author_tokens = list(self.get_author_tokens(authors, only_first_author=True))
|
||||
if author_tokens:
|
||||
q += ('+' if q else '') + build_term('author', author_tokens)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user