[Pleroma.Web.ActivityPub.Transmogrifier] Add Person finding
This commit is contained in:
parent
8472fba2a7
commit
7501481db4
@ -21,6 +21,11 @@ def get_actor(%{"actor" => actor}) when is_list(actor) do
|
||||
Enum.at(actor, 0)
|
||||
end
|
||||
|
||||
def get_actor(%{"actor" => actor_list}) do
|
||||
Enum.find(actor_list, fn %{"type" => type} -> type == "Person" end)
|
||||
|> Map.get("id")
|
||||
end
|
||||
|
||||
@doc """
|
||||
Modifies an incoming AP object (mastodon format) to our internal format.
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user