Clean out old emojis on reload
authorEkaterina Vaartis <vaartis@cock.li>
Mon, 12 Aug 2019 15:28:05 +0000 (18:28 +0300)
committerEkaterina Vaartis <vaartis@cock.li>
Wed, 18 Sep 2019 21:16:33 +0000 (00:16 +0300)
lib/pleroma/emoji.ex

index 2a9f5f8041e9e789f49f82aede7723823bad7058..f56b26da25f093bb4643b425bd8efb8c049cd606 100644 (file)
@@ -122,6 +122,9 @@ defmodule Pleroma.Emoji do
             fn pack -> load_pack(Path.join(emoji_dir_path, pack), emoji_groups) end
           )
 
+        # Clear out old emojis
+        :ets.delete_all_objects(@ets)
+
         true = :ets.insert(@ets, emojis)
     end