mirror of
https://git.pleroma.social/pleroma/pleroma.git
synced 2026-02-15 17:16:57 +00:00
Add changelog entry
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
This commit is contained in:
parent
d9a2c5c8a9
commit
731c249ac9
2 changed files with 1 additions and 4 deletions
1
changelog.d/fetcher-simple-policy.change
Normal file
1
changelog.d/fetcher-simple-policy.change
Normal file
|
|
@ -0,0 +1 @@
|
|||
Do not fetch anything from blocked instances
|
||||
|
|
@ -65,7 +65,6 @@ defmodule Pleroma.Object.Fetcher do
|
|||
{:ok, Object.t()} | {fetcher_errors(), any()} | Pipeline.errors()
|
||||
def fetch_object_from_id(id, options \\ []) do
|
||||
with %URI{} = uri <- URI.parse(id),
|
||||
# If we have instance restrictions, apply them here to prevent fetching from unwanted instances
|
||||
{_, {:ok, nil}} <- {:mrf_reject_accept_check, maybe_check_reject_accept(uri)},
|
||||
{_, nil} <- {:fetch_object, Object.get_cached_by_ap_id(id)},
|
||||
{_, true} <- {:allowed_depth, Federator.allowed_thread_distance?(options[:depth])},
|
||||
|
|
@ -88,9 +87,6 @@ defmodule Pleroma.Object.Fetcher do
|
|||
{:object, data, nil} ->
|
||||
reinject_object(%Object{}, data)
|
||||
|
||||
{:reject, reason} ->
|
||||
{:reject, reason}
|
||||
|
||||
e ->
|
||||
Logger.metadata(object: id)
|
||||
Logger.error("Object rejected while fetching #{id} #{inspect(e)}")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue