]> git.openstreetmap.org Git - rails.git/commit
Monkey patch MailDeliveryJob to work with delayed_job under ruby 3
authorTom Hughes <tom@compton.nu>
Sat, 23 Jul 2022 11:03:51 +0000 (12:03 +0100)
committerTom Hughes <tom@compton.nu>
Sat, 23 Jul 2022 11:12:29 +0000 (12:12 +0100)
commit21d52f2d3f3d83eb888543ec6c2a180e01d17baf
tree3f1d7bae403ed5ca6f2749a6030552c38b74bb3e
parent273cb9e00a9d1e553d0d24bec9dcc8957a3f85a9
Monkey patch MailDeliveryJob to work with delayed_job under ruby 3

The delayed_job gem does not currently perserve keyword arguments
properly leading to errors when running under ruby 3 and try to run
a job that requires them.

This affects our deferred mail deliveries so we monkey patch the
mail delivery job to unpack the hash from the normal arguments and
use it to provide the expected keyword arguments.

https://github.com/collectiveidea/delayed_job/issues/1134
config/initializers/mail_delivery_job.rb [new file with mode: 0644]