From 58835c64d22c472293b888d68857e8710164fb35 Mon Sep 17 00:00:00 2001 From: Mint <> Date: Thu, 10 Nov 2022 17:09:44 +0300 Subject: [PATCH] Fix 500s on reason search --- api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api.py b/api.py index 9931c25..17323be 100644 --- a/api.py +++ b/api.py @@ -42,7 +42,7 @@ def blocked(domain: str = None, reason: str = None): c.execute("select blocker, blocked, block_level, reason from blocks where blocked = ? or blocked = ? or blocked = ? or blocked = ? or blocked = ? or blocked = ?", (domain, "*." + domain, wildchar, get_hash(domain), punycode, "*." + punycode)) else: - c.execute("select * from blocks where reason like ? and reason != ''", ("%"+reason+"%",)) + c.execute("select blocker, blocked, block_level, reason from blocks where reason like ? and reason != ''", ("%"+reason+"%",)) blocks = c.fetchall() conn.close() -- 2.39.5