Merge branch 'develop' into 'feature/staff-discovery-api'
[akkoma] / lib / pleroma / web / twitter_api / twitter_api_controller.ex
index dfa6d2464102f1bfeeeba0f8c791310192f83318..b3a56b27ed74a31b9e588824acfdab69109a3c6e 100644 (file)
@@ -415,15 +415,16 @@ defmodule Pleroma.Web.TwitterAPI.Controller do
       if bio = params["description"] do
         mentions = Formatter.parse_mentions(bio)
         tags = Formatter.parse_tags(bio)
+
         emoji =
           (user.info["source_data"]["tag"] || [])
           |> Enum.filter(fn %{"type" => t} -> t == "Emoji" end)
           |> Enum.map(fn %{"icon" => %{"url" => url}, "name" => name} ->
             {String.trim(name, ":"), url}
           end)
+
         bio_html = CommonUtils.format_input(bio, mentions, tags)
-        |> Formatter.emojify(emoji)
-        Map.put(params, "bio", bio_html)
+        Map.put(params, "bio", bio_html |> Formatter.emojify(emoji))
       else
         params
       end