From 0c2f200b4d91f57e4669107c9bd042ae3b46d192 Mon Sep 17 00:00:00 2001 From: "Haelwenn (lanodan) Monnier" Date: Wed, 17 Apr 2024 07:37:41 +0200 Subject: [PATCH] =?UTF-8?q?ReceiverWorker:=20Make=20sure=20non-{:ok,=20=5F?= =?UTF-8?q?}=20is=20returned=20as=20{:error,=20=E2=80=A6}?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Otherwise an error like `{:signature, {:error, {:error, :not_found}}}` ends up considered a success. Cherry-picked-from: https://git.pleroma.social/pleroma/pleroma/-/commit/a299ddb10e5b682194710d97eed541277c9d22b6 --- lib/pleroma/workers/receiver_worker.ex | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/pleroma/workers/receiver_worker.ex b/lib/pleroma/workers/receiver_worker.ex index 9c3d8d1c2..a663a63fe 100644 --- a/lib/pleroma/workers/receiver_worker.ex +++ b/lib/pleroma/workers/receiver_worker.ex @@ -14,7 +14,8 @@ def perform(%Job{args: %{"op" => "incoming_ap_doc", "params" => params}}) do else {:error, :origin_containment_failed} -> {:discard, :origin_containment_failed} {:error, {:reject, reason}} -> {:discard, reason} - e -> e + {:error, _} = e -> e + e -> {:error, e} end end end