Handle incoming review
This commit is contained in:
parent
b2b651a22f
commit
c4ce4ae47e
2 changed files with 43 additions and 4 deletions
|
@ -9,6 +9,8 @@ def get_or_create_book(olkey, user=None, update=True):
|
|||
# check if this is a valid open library key, and a book
|
||||
olkey = olkey
|
||||
response = requests.get(OL_URL + olkey + '.json')
|
||||
if not response.ok:
|
||||
response.raise_for_status()
|
||||
|
||||
# get the existing entry from our db, if it exists
|
||||
try:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue