mirror of
https://github.com/discourse/discourse.git
synced 2025-06-02 04:08:41 +08:00
FIX: Fixed custom emoji circumventing "max emojis in topic title" set… (#7116)
This commit is contained in:
@ -230,10 +230,11 @@ module PrettyText
|
||||
return title unless SiteSetting.enable_emoji?
|
||||
|
||||
set = SiteSetting.emoji_set.inspect
|
||||
custom = Emoji.custom.map { |e| [e.name, e.url] }.to_h.to_json
|
||||
protect do
|
||||
v8.eval(<<~JS)
|
||||
__paths = #{paths_json};
|
||||
__performEmojiUnescape(#{title.inspect}, { getURL: __getURL, emojiSet: #{set} });
|
||||
__performEmojiUnescape(#{title.inspect}, { getURL: __getURL, emojiSet: #{set}, customEmoji: #{custom} });
|
||||
JS
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user