From: Roland Häder Date: Sun, 10 Dec 2023 22:08:50 +0000 (+0100) Subject: Continued: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=c457f1e1a8507b99ba204172464a350dad220731;p=fba.git Continued: - Python still needs a backslash here --- diff --git a/daemon.py b/daemon.py index c876651..695ab04 100755 --- a/daemon.py +++ b/daemon.py @@ -472,10 +472,10 @@ def rss(request: Request, domain: str = None): wildchar = "*." + ".".join(domain.split(".")[-domain.count("."):]) punycode = domain.encode("idna").decode("utf-8") - database.cursor.execute("SELECT blocker, blocked, block_level, reason, first_seen, last_seen -FROM blocks -WHERE blocked = ? OR blocked = ? OR blocked = ? OR blocked = ? OR blocked = ? OR blocked = ? -ORDER BY first_seen DESC + database.cursor.execute("SELECT blocker, blocked, block_level, reason, first_seen, last_seen \ +FROM blocks \ +WHERE blocked = ? OR blocked = ? OR blocked = ? OR blocked = ? OR blocked = ? OR blocked = ? \ +ORDER BY first_seen DESC \ LIMIT ?", [ domain, "*." + domain, wildchar, @@ -485,9 +485,9 @@ LIMIT ?", [ config.get("rss_limit") ]) else: - database.cursor.execute("SELECT blocker, blocked, block_level, reason, first_seen, last_seen -FROM blocks -ORDER BY first_seen DESC + database.cursor.execute("SELECT blocker, blocked, block_level, reason, first_seen, last_seen \ +FROM blocks \ +ORDER BY first_seen DESC \ LIMIT ?", [config.get("rss_limit")]) result = database.cursor.fetchall()