From a5d21852bbf3c64684f008bb05db6d7da7b65d76 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Fri, 16 Oct 2020 20:52:27 +0100 Subject: [PATCH] Avoid lone hashes --- newswire.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/newswire.py b/newswire.py index bec28b701..57f992f9f 100644 --- a/newswire.py +++ b/newswire.py @@ -66,8 +66,9 @@ def getNewswireTags(text: str) -> []: tags = [] for wrd in words: if wrd.startswith('#'): - if wrd not in tags: - tags.append(wrd) + if len(wrd) > 1: + if wrd not in tags: + tags.append(wrd) return tags