From e7d487f353ab05d81cc31c05e647a2e106a0e2aa Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Tue, 23 May 2023 13:56:05 +0200 Subject: [PATCH] Continued: - if the software being used isn't regonized, skip them --- api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api.py b/api.py index 0174a8d..131ea38 100644 --- a/api.py +++ b/api.py @@ -42,7 +42,7 @@ def top(blocked: int = None, blockers: int = None, reference: int = None, softwa elif software != None: if software > 500: raise HTTPException(status_code=400, detail="Too many results") - fba.cursor.execute("SELECT software, COUNT(domain) FROM instances GROUP BY software ORDER BY COUNT(domain) DESC LIMIT ?", [software]) + fba.cursor.execute("SELECT software, COUNT(domain) FROM instances WHERE software IS NOT NULL GROUP BY software ORDER BY COUNT(domain) DESC LIMIT ?", [software]) else: raise HTTPException(status_code=400, detail="No filter specified") -- 2.39.5