diff --git a/posts.py b/posts.py index 05da2c3b5..a129f1ae4 100644 --- a/posts.py +++ b/posts.py @@ -2667,7 +2667,8 @@ def mutePost(baseDir: str,nickname: str,domain: str,postId: str, \ if postId in recentPostsCache['index']: print('MUTE: '+postId+' is in recent posts cache') if recentPostsCache['json'].get(postId): - recentPostsCache['json'][postId]['muted']=True + postJsonObject['muted']=True + recentPostsCache['json'][postId]=json.dumps(postJsonObject) print('MUTE: '+postId+' marked as muted in recent posts cache') def unmutePost(baseDir: str,nickname: str,domain: str,postId: str, \ @@ -2697,5 +2698,6 @@ def unmutePost(baseDir: str,nickname: str,domain: str,postId: str, \ if postId in recentPostsCache['index']: print('UNMUTE: '+postId+' is in recent posts cache') if recentPostsCache['json'].get(postId): - recentPostsCache['json'][postId]['muted']=False + postJsonObject['muted']=False + recentPostsCache['json'][postId]=json.dumps(postJsonObject) print('UNMUTE: '+postId+' marked as not muted in recent posts cache')