dont add empty subtitle
This commit is contained in:
parent
f57b75ac03
commit
094097b26d
1 changed files with 1 additions and 1 deletions
|
@ -63,7 +63,7 @@ def info(key, value):
|
||||||
'publishedDate': 'date',
|
'publishedDate': 'date',
|
||||||
}.get(key,key)] = _data[key]
|
}.get(key,key)] = _data[key]
|
||||||
|
|
||||||
if 'subtitle' in _data:
|
if 'subtitle' in _data and _data['subtitle'].strip():
|
||||||
data['title'] = '{title}: {subtitle}'.format(**_data)
|
data['title'] = '{title}: {subtitle}'.format(**_data)
|
||||||
if r['items'][0]['accessInfo']['viewability'] != 'NO_PAGES':
|
if r['items'][0]['accessInfo']['viewability'] != 'NO_PAGES':
|
||||||
data['cover'] = 'https://books.google.com/books?id=%s&pg=PP1&img=1&zoom=0&hl=en' % r['items'][0]['id']
|
data['cover'] = 'https://books.google.com/books?id=%s&pg=PP1&img=1&zoom=0&hl=en' % r['items'][0]['id']
|
||||||
|
|
Loading…
Reference in a new issue