Append custom emoji

main
Bob Mottram 2021-11-01 22:45:57 +00:00
parent 4bcc4930d2
commit 3a31230f9c
1 changed files with 7 additions and 0 deletions

View File

@ -900,6 +900,13 @@ def addHtmlTags(baseDir: str, httpPrefix: str,
baseDir + '/emoji/emoji.json')
emojiDict = loadJson(baseDir + '/emoji/emoji.json')
# append custom emoji to the dict
if os.path.isfile(baseDir + '/emojicustom/emoji.json'):
customEmojiDict = \
loadJson(baseDir + '/emojicustom/emoji.json')
emojiDict = \
dict(emojiDict.items() + customEmojiDict.items())
# print('TAG: looking up emoji for :' + wordStr2 + ':')
_addEmoji(baseDir, ':' + wordStr2 + ':', httpPrefix,
originalDomain, replaceEmoji, hashtags,