Commit b6d3eadf authored by Grzegorz Bizon's avatar Grzegorz Bizon

Fix method visiblity in emoji filter class

parent 3d2b6a3d
...@@ -38,6 +38,11 @@ module Banzai ...@@ -38,6 +38,11 @@ module Banzai
end end
end end
# Build a regexp that matches all valid :emoji: names.
def self.emoji_pattern
@emoji_pattern ||= /:(#{Gitlab::Emoji.emojis_names.map { |name| Regexp.escape(name) }.join('|')}):/
end
private private
def emoji_url(name) def emoji_url(name)
...@@ -59,11 +64,6 @@ module Banzai ...@@ -59,11 +64,6 @@ module Banzai
ActionController::Base.helpers.url_to_image(image) ActionController::Base.helpers.url_to_image(image)
end end
# Build a regexp that matches all valid :emoji: names.
def self.emoji_pattern
@emoji_pattern ||= /:(#{Gitlab::Emoji.emojis_names.map { |name| Regexp.escape(name) }.join('|')}):/
end
def emoji_pattern def emoji_pattern
self.class.emoji_pattern self.class.emoji_pattern
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment