From 54519a2976a2ccd8e1251b6ad2839362cfaf244e Mon Sep 17 00:00:00 2001 From: Joffrey JAFFEUX Date: Sun, 6 Dec 2020 18:28:39 +0100 Subject: [PATCH] FIX: do not replace smiling_face by slight_smile (#11412) --- app/models/emoji.rb | 1 - spec/components/pretty_text_spec.rb | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/app/models/emoji.rb b/app/models/emoji.rb index f7c7b70c909..b4698c568e9 100644 --- a/app/models/emoji.rb +++ b/app/models/emoji.rb @@ -173,7 +173,6 @@ class Emoji end replacements["\u{2639}"] = 'frowning' - replacements["\u{263A}"] = 'slight_smile' replacements["\u{263B}"] = 'slight_smile' replacements["\u{2661}"] = 'heart' replacements["\u{2665}"] = 'heart' diff --git a/spec/components/pretty_text_spec.rb b/spec/components/pretty_text_spec.rb index 887dcfba9c1..cb574b096c1 100644 --- a/spec/components/pretty_text_spec.rb +++ b/spec/components/pretty_text_spec.rb @@ -1037,7 +1037,7 @@ describe PrettyText do end it "replaces some glyphs that are not in the emoji range" do - expect(PrettyText.cook("☺")).to match(/\:slight_smile\:/) + expect(PrettyText.cook("☺")).to match(/\:relaxed\:/) end it "replaces digits" do