From 240c1227671f5b6e269f82754cd5bacada07a005 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 21 Dec 2018 06:16:17 +0100 Subject: [PATCH] Skip mailer job retries when a record no longer exists (#9590) Fix #8666 --- config/initializers/delivery_job.rb | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 config/initializers/delivery_job.rb diff --git a/config/initializers/delivery_job.rb b/config/initializers/delivery_job.rb new file mode 100644 index 0000000000..cc29272729 --- /dev/null +++ b/config/initializers/delivery_job.rb @@ -0,0 +1,3 @@ +ActionMailer::DeliveryJob.class_eval do + discard_on ActiveJob::DeserializationError +end