Use Pleroma.Object.Containment.get_actor/1 to reliably find the actor of an incoming activity or object

This commit is contained in:
feld 2024-08-24 16:53:22 +00:00 committed by Mark Felder
parent 1c394dd18c
commit 27fcc42171

View file

@ -567,9 +567,8 @@ defmodule Pleroma.Web.ActivityPub.ActivityPubController do
defp unknown_delete?(%{
"type" => "Delete",
"actor" => actor
}) do
case User.get_cached_by_ap_id(actor) do
} = data) do
case data |> Pleroma.Object.Containment.get_actor() |> User.get_cached_by_ap_id() do
%User{} -> false
_ -> true
end