From b051e68bb025417738579b027e4b039ffb9b19da Mon Sep 17 00:00:00 2001 From: Mark Felder Date: Fri, 12 Jul 2024 10:15:02 -0400 Subject: [PATCH] Discard Remote Fetcher jobs which errored due to an MRF rejection --- changelog.d/oban-fetcher-rejected.change | 1 + lib/pleroma/workers/remote_fetcher_worker.ex | 3 +++ 2 files changed, 4 insertions(+) create mode 100644 changelog.d/oban-fetcher-rejected.change diff --git a/changelog.d/oban-fetcher-rejected.change b/changelog.d/oban-fetcher-rejected.change new file mode 100644 index 000000000..92e083647 --- /dev/null +++ b/changelog.d/oban-fetcher-rejected.change @@ -0,0 +1 @@ +Discard Remote Fetcher jobs which errored due to an MRF rejection diff --git a/lib/pleroma/workers/remote_fetcher_worker.ex b/lib/pleroma/workers/remote_fetcher_worker.ex index ed04c54b2..debbbe012 100644 --- a/lib/pleroma/workers/remote_fetcher_worker.ex +++ b/lib/pleroma/workers/remote_fetcher_worker.ex @@ -13,6 +13,9 @@ defmodule Pleroma.Workers.RemoteFetcherWorker do {:ok, _object} -> :ok + {:rejected, reason} -> + {:discard, reason} + {:error, :forbidden} -> {:discard, :forbidden}