From 880b1be4017f3ab9b5e286efb8847b74eef49c6b Mon Sep 17 00:00:00 2001 From: Mizaki Date: Thu, 10 Nov 2022 16:15:27 +0000 Subject: [PATCH] Return zero score if there is no image url. Fixes #392 --- comictaggerlib/issueidentifier.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/comictaggerlib/issueidentifier.py b/comictaggerlib/issueidentifier.py index 091e7a1..4f6d316 100644 --- a/comictaggerlib/issueidentifier.py +++ b/comictaggerlib/issueidentifier.py @@ -251,6 +251,10 @@ class IssueIdentifier: # local_cover_hash_list is a list of pre-calculated hashes. # use_remote_alternates - indicates to use alternate covers from CV + # If there is no URL return 0 + if not primary_img_url: + return Score(score=0, url="", hash=0) + try: url_image_data = ImageFetcher().fetch(primary_thumb_url, blocking=True) except ImageFetcherException as e: