You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by gc...@apache.org on 2022/11/02 18:11:53 UTC
[allura] 11/15: [#8474] emojize argument update
This is an automated email from the ASF dual-hosted git repository.
gcruz pushed a commit to branch gc/8474
in repository https://gitbox.apache.org/repos/asf/allura.git
commit f77a257f4d9ae49f78295dc51da96eae771b45c5
Author: Guillermo Cruz <gu...@slashdotmedia.com>
AuthorDate: Thu Oct 27 10:52:16 2022 -0600
[#8474] emojize argument update
---
Allura/allura/lib/helpers.py | 2 +-
Allura/allura/lib/markdown_extensions.py | 2 +-
Allura/allura/lib/utils.py | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/Allura/allura/lib/helpers.py b/Allura/allura/lib/helpers.py
index 2efce7911..da5f3e954 100644
--- a/Allura/allura/lib/helpers.py
+++ b/Allura/allura/lib/helpers.py
@@ -1288,7 +1288,7 @@ def hide_private_info(message):
def emojize(text):
"""Coverts emoji codes to unicode emojis"""
- return emoji.emojize(text, use_aliases=True)
+ return emoji.emojize(text, language="alias")
def get_current_reaction(react_users_dict):
diff --git a/Allura/allura/lib/markdown_extensions.py b/Allura/allura/lib/markdown_extensions.py
index b929a6b7a..c1d089d77 100644
--- a/Allura/allura/lib/markdown_extensions.py
+++ b/Allura/allura/lib/markdown_extensions.py
@@ -311,7 +311,7 @@ class EmojiInlinePattern(markdown.inlinepatterns.Pattern):
def handleMatch(self, m):
emoji_code = m.group(2)
- return emoji.emojize(emoji_code, use_aliases=True)
+ return emoji.emojize(emoji_code, language="alias")
class UserMentionExtension(markdown.Extension):
diff --git a/Allura/allura/lib/utils.py b/Allura/allura/lib/utils.py
index b6e7ee0de..41b2c979f 100644
--- a/Allura/allura/lib/utils.py
+++ b/Allura/allura/lib/utils.py
@@ -761,7 +761,7 @@ def get_reactions_json():
""" Returns global reactions json """
j = OrderedDict()
for em in get_reaction_emoji_list():
- j[em] = emoji.emojize(em, use_aliases=True)
+ j[em] = emoji.emojize(em, language='alias')
return json.dumps(j)