Changeset - f5ed6b020878
[Not reviewed]
default
0 1 0
Dennis Fink - 2 years ago 2022-03-21 20:55:40
dennis.fink@c3l.lu
Don't fail if the book has not isbn
1 file changed with 4 insertions and 0 deletions:
0 comments (0 inline, 0 general)
stockcli/books.py
Show inline comments
 
@@ -28,6 +28,10 @@ def add_book_by_barcode(barcode: str) ->
 
        book_metadata = utils.get_request(
 
            f"userfields/userentity-books/{book['id']}", cached=True
 
        )
 

	
 
        if book_metadata["isbn"] is None:
 
            continue
 

	
 
        if isbnlib.canonical(book_metadata["isbn"]) == canonical_isbn:
 

	
 
            book_metadata = utils.get_request(
0 comments (0 inline, 0 general)