Support users with no shared inbox
This commit is contained in:
parent
9360f4512c
commit
ef2209e77b
6 changed files with 12 additions and 8 deletions
|
@ -15,10 +15,9 @@ def book_search(query):
|
|||
data = response.json()
|
||||
results = []
|
||||
for doc in data['docs'][:5]:
|
||||
key = doc['key'].split('/')[-1]
|
||||
results.append({
|
||||
'title': doc['title'],
|
||||
'olkey': key,
|
||||
'olkey': doc['key'],
|
||||
'year': doc['first_publish_year'],
|
||||
'author': doc['author_name'][0],
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue