SideEffects: Use Object.normalize to get the object.

This commit is contained in:
lain 2020-04-28 13:43:58 +02:00
parent 906cf53ab9
commit f8e56d4271

View file

@ -30,8 +30,8 @@ defmodule Pleroma.Web.ActivityPub.SideEffects do
result
end
def handle(%{data: %{"type" => "Create", "object" => object_id}} = activity, meta) do
object = Object.get_by_ap_id(object_id)
def handle(%{data: %{"type" => "Create"}} = activity, meta) do
object = Object.normalize(activity, false)
{:ok, _object} = handle_object_creation(object)