check for empty return

This commit is contained in:
Jakob Ketterl 2021-05-04 16:05:44 +02:00
parent a17690dc91
commit cd935c0dcb

View File

@ -66,7 +66,7 @@ class DmrMetaEnricher(object):
self.threads[id].start()
return meta
data = cache.get(id)
if "count" in data and data["count"] > 0 and "results" in data:
if data is not None and "count" in data and data["count"] > 0 and "results" in data:
meta["additional"] = data["results"][0]
return meta