From 962a0b873d7066e9adb002ff31131fba8ae683f9 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 26 Mar 2009 00:31:19 -0700 Subject: [PATCH] Fix #2144 (Calibre not searching by title/author when using Google Books API) --- src/calibre/ebooks/metadata/google_books.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/calibre/ebooks/metadata/google_books.py b/src/calibre/ebooks/metadata/google_books.py index d26445141a..a2eaf6cae4 100644 --- a/src/calibre/ebooks/metadata/google_books.py +++ b/src/calibre/ebooks/metadata/google_books.py @@ -60,9 +60,9 @@ class Query(object): if title is not None: q += build_term('title', title.split()) if author is not None: - q += build_term('author', author.split()) + q += ('+' if q else '')+build_term('author', author.split()) if publisher is not None: - q += build_term('publisher', publisher.split()) + q += ('+' if q else '')+build_term('publisher', publisher.split()) if isinstance(q, unicode): q = q.encode('utf-8')