From 972c29a9fa5f6cd76c809042f2ee75ada250c0f2 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Tue, 5 Jul 2022 17:25:31 +0100 Subject: [PATCH] Require a category --- content.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/content.py b/content.py index c23b5e9a5..2a079839d 100644 --- a/content.py +++ b/content.py @@ -1027,6 +1027,8 @@ def detect_dogwhistles(content: str, dogwhistles: {}) -> {}: result = {} words = _get_simplified_content(content).split(' ') for whistle, category in dogwhistles.items(): + if not category: + continue ending = False starting = False