mirror of https://gitlab.com/bashrc2/epicyon
Add emoji to CW
parent
2083a2d59a
commit
14fbed456a
|
@ -1498,8 +1498,12 @@ def individualPostAsHtml(allowDownloads: bool,
|
|||
postID = 'post' + str(createPassword(8))
|
||||
contentStr = ''
|
||||
if postJsonObject['object'].get('summary'):
|
||||
contentStr += \
|
||||
'<b>' + str(postJsonObject['object']['summary']) + '</b>\n '
|
||||
cwStr = str(postJsonObject['object']['summary'])
|
||||
cwStr = \
|
||||
addEmojiToDisplayName(baseDir, httpPrefix,
|
||||
nickname, domain,
|
||||
cwStr, False)
|
||||
contentStr += '<b>' + cwStr + '</b>\n '
|
||||
if isModerationPost:
|
||||
containerClass = 'container report'
|
||||
# get the content warning text
|
||||
|
|
|
@ -576,7 +576,7 @@ def loadIndividualPostAsHtmlFromCache(baseDir: str,
|
|||
def addEmojiToDisplayName(baseDir: str, httpPrefix: str,
|
||||
nickname: str, domain: str,
|
||||
displayName: str, inProfileName: bool) -> str:
|
||||
"""Adds emoji icons to display names on individual posts
|
||||
"""Adds emoji icons to display names or CW on individual posts
|
||||
"""
|
||||
if ':' not in displayName:
|
||||
return displayName
|
||||
|
|
Loading…
Reference in New Issue