PollWorker jobs will not retry if the activity no longer exists.
This commit is contained in:
parent
e509519db4
commit
b8503f1ad4
1
changelog.d/oban-cancel-poll-result.change
Normal file
1
changelog.d/oban-cancel-poll-result.change
Normal file
@ -0,0 +1 @@
|
||||
PollWorker jobs will not retry if the activity no longer exists.
|
@ -17,6 +17,9 @@ defmodule Pleroma.Workers.PollWorker do
|
||||
with %Activity{} = activity <- find_poll_activity(activity_id),
|
||||
{:ok, notifications} <- Notification.create_poll_notifications(activity) do
|
||||
Notification.stream(notifications)
|
||||
else
|
||||
{:error, :poll_activity_not_found} = e -> {:cancel, e}
|
||||
e -> {:error, e}
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user