Don't show DMs if unauthorized

merge-requests/30/head
Bob Mottram 2021-01-08 21:40:05 +00:00
parent 155493c0d0
commit 80545e279a
1 changed files with 4 additions and 2 deletions

View File

@ -3091,6 +3091,8 @@ def _createBoxIndexed(recentPostsCache: {},
if not authorized: if not authorized:
if p.get('object'): if p.get('object'):
if isinstance(p['object'], dict): if isinstance(p['object'], dict):
if isDM(p):
continue
if p['object'].get('likes'): if p['object'].get('likes'):
p['likes'] = {'items': []} p['likes'] = {'items': []}
if p['object'].get('replies'): if p['object'].get('replies'):