diff options
author | Mark Felder <feld@feld.me> | 2021-02-09 18:51:59 -0600 |
---|---|---|
committer | Mark Felder <feld@feld.me> | 2021-02-09 18:52:22 -0600 |
commit | 4540e08a6a19cea753e1271ebc9f79bf2e4c47ce (patch) | |
tree | ffe4facb520afad788b550cbaab0cb93e2271e5c | |
parent | 981349f21d401da55168fdb00b245e3dccea1afd (diff) | |
download | pleroma-4540e08a6a19cea753e1271ebc9f79bf2e4c47ce.tar.gz |
Rendering fallback for when we don't have valid data available
-rw-r--r-- | lib/pleroma/web/mastodon_api/views/status_view.ex | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/pleroma/web/mastodon_api/views/status_view.ex b/lib/pleroma/web/mastodon_api/views/status_view.ex index e4f623b97..38960c256 100644 --- a/lib/pleroma/web/mastodon_api/views/status_view.ex +++ b/lib/pleroma/web/mastodon_api/views/status_view.ex @@ -180,7 +180,7 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do media_attachments: reblogged[:media_attachments] || [], mentions: mentions, tags: reblogged[:tags] || [], - application: activity_object.data["application"], + application: activity_object.data["application"] || %{name: "Web", website: nil}, language: nil, emojis: [], pleroma: %{ @@ -345,7 +345,7 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do poll: render(PollView, "show.json", object: object, for: opts[:for]), mentions: mentions, tags: build_tags(tags), - application: object.data["application"], + application: object.data["application"] || %{name: "Web", website: nil}, language: nil, emojis: build_emojis(object.data["emoji"]), pleroma: %{ |