diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2017-07-22 09:47:24 -0500 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2017-07-22 09:47:24 -0500 |
commit | d50679f4eefde1aca1ab71ba3c0109739cfdff3f (patch) | |
tree | ac9034fe7c4aa64cd5e90ecebc346d478917387c /app/jobs | |
parent | 5b7c31c23a708de77b3d73b68aec0ba99c8be861 (diff) | |
download | rails-d50679f4eefde1aca1ab71ba3c0109739cfdff3f.tar.gz rails-d50679f4eefde1aca1ab71ba3c0109739cfdff3f.tar.bz2 rails-d50679f4eefde1aca1ab71ba3c0109739cfdff3f.zip |
Move models and jobs to the app setup
Follow engine conventions more closely
Diffstat (limited to 'app/jobs')
-rw-r--r-- | app/jobs/active_storage/purge_job.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/app/jobs/active_storage/purge_job.rb b/app/jobs/active_storage/purge_job.rb new file mode 100644 index 0000000000..b59d3687f8 --- /dev/null +++ b/app/jobs/active_storage/purge_job.rb @@ -0,0 +1,10 @@ +require "active_job" + +class ActiveStorage::PurgeJob < ActiveJob::Base + # FIXME: Limit this to a custom ActiveStorage error + retry_on StandardError + + def perform(attachment_or_blob) + attachment_or_blob.purge + end +end |