diff options
author | lain <lain@soykaf.club> | 2018-02-24 22:28:22 +0100 |
---|---|---|
committer | lain <lain@soykaf.club> | 2018-02-24 22:28:22 +0100 |
commit | 0e9bd6d1485e56f81da8fcde6b40d8981f63b113 (patch) | |
tree | c1b13c837249ff65f09c452eb1f3f3de765e58e4 /lib | |
parent | 7e0ce32f4d9693e475c03b1ea60ba63fe75ba7bb (diff) | |
download | pleroma-0e9bd6d1485e56f81da8fcde6b40d8981f63b113.tar.gz |
Hotfix for tag problems.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pleroma/web/ostatus/activity_representer.ex | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/lib/pleroma/web/ostatus/activity_representer.ex b/lib/pleroma/web/ostatus/activity_representer.ex index 33e5e0009..c8ade52a4 100644 --- a/lib/pleroma/web/ostatus/activity_representer.ex +++ b/lib/pleroma/web/ostatus/activity_representer.ex @@ -79,7 +79,14 @@ defmodule Pleroma.Web.OStatus.ActivityRepresenter do mentions = activity.recipients |> get_mentions categories = (activity.data["object"]["tag"] || []) - |> Enum.map(fn (tag) -> {:category, [term: to_charlist(tag)], []} end) + |> Enum.map(fn (tag) -> + if is_binary(tag) do + {:category, [term: to_charlist(tag)], []} + else + nil + end + end) + |> Enum.filter(&(&1)) emoji_links = get_emoji_links(activity.data["object"]["emoji"] || %{}) |