UX: Better emoji escaping for topic title (#7218)

* FIX: Fixed failing discourse-prometheus-alert-receiver plugin specs
This commit is contained in:
Tim Lange
2019-03-21 09:11:33 +01:00
committed by Régis Hanol
parent 6450969c7b
commit f7b156ffbd
7 changed files with 74 additions and 26 deletions

View File

@@ -157,13 +157,7 @@ class Emoji
end
def self.unicode_unescape(string)
string.each_char.map do |c|
if str = unicode_replacements[c]
":#{str}:"
else
c
end
end.join
PrettyText.escape_emoji(string)
end
def self.gsub_emoji_to_unicode(str)