From 5b2aa4d31f7810e513b56720f4533ea18207bdcf Mon Sep 17 00:00:00 2001 From: dullcibus <73450288+dullcibus@users.noreply.github.com> Date: Sun, 24 Jul 2022 00:13:59 +0000 Subject: [PATCH] Make results count work no matter if api returns int or str api seems to sometimes return str and sometimes int. --- resce.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resce.py b/resce.py index d6d68d0..7acfecd 100755 --- a/resce.py +++ b/resce.py @@ -464,7 +464,7 @@ def srrdbidentify(crc): if len(str(sys.exc_info()[1])) > 0: print sys.exc_info()[1] - if not response or response['resultsCount'] != '1': + if not response or int(response['resultsCount']) < 1: print 'not found.' return False