defmodule Pleroma.Object.Fetcher do
+ alias Pleroma.HTTP
alias Pleroma.Object
alias Pleroma.Object.Containment
alias Pleroma.Web.ActivityPub.Transmogrifier
require Logger
- @httpoison Application.get_env(:pleroma, :httpoison)
-
defp reinject_object(data) do
Logger.debug("Reinjecting object #{data["id"]}")
with true <- String.starts_with?(id, "http"),
{:ok, %{body: body, status: code}} when code in 200..299 <-
- @httpoison.get(
+ HTTP.get(
id,
[{:Accept, "application/activity+json"}]
),