Remove duplicate log messages from Transmogrifier
Object fetch errors are logged in the fetcher module
This commit is contained in:
parent
becb070603
commit
882267e3ec
|
@ -23,7 +23,6 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier do
|
||||||
|
|
||||||
import Ecto.Query
|
import Ecto.Query
|
||||||
|
|
||||||
require Logger
|
|
||||||
require Pleroma.Constants
|
require Pleroma.Constants
|
||||||
|
|
||||||
@doc """
|
@doc """
|
||||||
|
@ -155,8 +154,7 @@ def fix_in_reply_to(%{"inReplyTo" => in_reply_to} = object, options)
|
||||||
|> Map.put("context", replied_object.data["context"] || object["conversation"])
|
|> Map.put("context", replied_object.data["context"] || object["conversation"])
|
||||||
|> Map.drop(["conversation", "inReplyToAtomUri"])
|
|> Map.drop(["conversation", "inReplyToAtomUri"])
|
||||||
else
|
else
|
||||||
e ->
|
_ ->
|
||||||
Logger.warning("Couldn't fetch #{inspect(in_reply_to_id)}, error: #{inspect(e)}")
|
|
||||||
object
|
object
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
|
@ -181,8 +179,7 @@ def fix_quote_url_and_maybe_fetch(object, options \\ []) do
|
||||||
{:quoting?, _} ->
|
{:quoting?, _} ->
|
||||||
object
|
object
|
||||||
|
|
||||||
e ->
|
_ ->
|
||||||
Logger.warning("Couldn't fetch #{inspect(quote_url)}, error: #{inspect(e)}")
|
|
||||||
object
|
object
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -852,8 +849,7 @@ def maybe_fix_object_url(%{"object" => object} = data) when is_binary(object) do
|
||||||
relative_object do
|
relative_object do
|
||||||
Map.put(data, "object", external_url)
|
Map.put(data, "object", external_url)
|
||||||
else
|
else
|
||||||
{:fetch, e} ->
|
{:fetch, _} ->
|
||||||
Logger.error("Couldn't fetch #{object} #{inspect(e)}")
|
|
||||||
data
|
data
|
||||||
|
|
||||||
_ ->
|
_ ->
|
||||||
|
|
Loading…
Reference in New Issue