From 08b98516f9555873abada1848e4710018b2cf70c Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Fri, 13 Dec 2019 09:46:46 +0000 Subject: [PATCH] Don't show blocked hashtags --- webinterface.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/webinterface.py b/webinterface.py index 20929951..473fc0d5 100644 --- a/webinterface.py +++ b/webinterface.py @@ -48,6 +48,7 @@ from like import noOfLikes from bookmarks import bookmarkedByPerson from announce import announcedByPerson from blocking import isBlocked +from blocking import isBlockedHashtag from content import getMentionsFromHtml from content import addHtmlTags from content import replaceEmojiFromTags @@ -3757,6 +3758,9 @@ def htmlHashTagCloud(baseDir: str,path: str) -> str: tagsFilename=os.path.join(baseDir+'/tags',f) if not os.path.isfile(tagsFilename): continue + hashTagName=f.split('.')[0] + if isBlockedHashtag(baseDir,hashTagName): + continue if daysSinceEpochStr not in open(tagsFilename).read(): continue with open(tagsFilename, 'r') as tagsFile: @@ -3771,7 +3775,7 @@ def htmlHashTagCloud(baseDir: str,path: str) -> str: if postDaysSinceEpoch