Insert text representation of hashtags into object["hashtags"]
[akkoma] / lib / pleroma / activity / ir / topics.ex
index fe2e8cb5c900d7b84f0e92bc1ba42a74c85d685b..2cdecf1e4c67e667be717d0e5d28cae6ad810efa 100644 (file)
@@ -48,6 +48,10 @@ defmodule Pleroma.Activity.Ir.Topics do
     tags
   end
 
+  defp hashtags_to_topics(%{data: %{"hashtags" => tags}}) do
+    Enum.map(tags, fn tag -> "hashtag:" <> tag end)
+  end
+
   defp hashtags_to_topics(%{data: %{"tag" => tags}}) do
     tags
     |> Enum.filter(&is_bitstring(&1))