Backfetch without a second layer of indirection

This commit is contained in:
TudbuT 2024-10-29 07:26:36 +01:00 committed by tudbut
parent f08ca527ff
commit de1a5f6224

View file

@ -17,7 +17,8 @@ def perform(%Job{args: %{"op" => "fetch_outbox", "id" => address}}) do
with {:ok, outbox} <- ActivityPub.fetch_and_prepare_outbox_from_ap_id(address) do
Enum.each(Enum.reverse(outbox), fn {ap_id, _} ->
if is_nil(Object.get_cached_by_ap_id(ap_id)) do
enqueue("fetch_remote", %{
perform(%{
"op" => "fetch_remote",
"id" => ap_id,
"depth" => 1
})