TwitterAPI.ActivityView: Ignore unhandled activities

This commit is contained in:
href 2018-12-14 17:24:33 +01:00
parent 30dc81667c
commit 84b9a9d497
No known key found for this signature in database
GPG Key ID: EE8296C1A152C325
1 changed files with 6 additions and 0 deletions

View File

@ -14,6 +14,7 @@ defmodule Pleroma.Web.TwitterAPI.ActivityView do
alias Pleroma.HTML
import Ecto.Query
require Logger
defp query_context_ids([]), do: []
@ -276,6 +277,11 @@ def render(
}
end
def render("activity.json", %{activity: unhandled_activity}) do
Logger.warn("#{__MODULE__} unhandled activity: #{inspect(unhandled_activity)}")
nil
end
def render_content(%{"type" => "Note"} = object) do
summary = object["summary"]