Verified Commit f3291acc authored by Haelwenn's avatar Haelwenn
Browse files

transmogrifier: pro-actively add support for Hashtag without array in tag

parent 2c820e10
......@@ -206,6 +206,13 @@ def fix_tag(%{"tag" => tag} = object) when is_list(tag) do
|> Map.put("tag", combined)
end
def fix_tag(%{"tag" => %{"type" => "Hashtag"} = tag} = object) do
combined = [tag ++ String.slice(tag["name"], 1..-1)]
object
|> Map.put("tag", combined)
end
def fix_tag(object) do
object
end
......
Supports Markdown
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