diff --git a/blog.py b/blog.py index a1efa5e2..4c3e83c7 100644 --- a/blog.py +++ b/blog.py @@ -233,7 +233,28 @@ def htmlBlogPostContent(authorized: bool, 'content') blogStr += '
' + contentStr + '\n' - blogStr += '
\n' + citationsStr = '' + if postJsonObject['object'].get('tag'): + for tagJson in postJsonObject['object']['tag']: + if not isinstance(tagJson, dict): + continue + if not tagJson.get('type'): + continue + if tagJson['type'] != 'Article': + continue + if not tagJson.get('name'): + continue + if not tagJson.get('url'): + continue + citationsStr += \ + '
  • ' + \ + '' + tagJson['name'] + '
  • \n' + if citationsStr: + citationsStr = '

    ' + translate['Citations'] + \ + ':

    ' + \ + '\n' + + blogStr += '
    \n' + citationsStr if not linkedAuthor: blogStr += '