Check that tags are dicts

main
Bob Mottram 2020-11-06 13:51:57 +00:00
parent a1b2bcd5b6
commit 309fd923bd
1 changed files with 2 additions and 0 deletions

View File

@ -5588,6 +5588,8 @@ def individualPostAsHtml(allowDownloads: bool,
if boxName == 'tlblog': if boxName == 'tlblog':
if postJsonObject['object'].get('tag'): if postJsonObject['object'].get('tag'):
for tagJson in postJsonObject['object']['tag']: for tagJson in postJsonObject['object']['tag']:
if not isinstance(tagJson, dict):
continue
if not tagJson.get('type'): if not tagJson.get('type'):
continue continue
if tagJson['type'] != 'Article': if tagJson['type'] != 'Article':