aboutsummaryrefslogtreecommitdiffstats
path: root/lib/active_job/queue_adapters/sucker_punch_adapter.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/active_job/queue_adapters/sucker_punch_adapter.rb')
-rw-r--r--lib/active_job/queue_adapters/sucker_punch_adapter.rb11
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/active_job/queue_adapters/sucker_punch_adapter.rb b/lib/active_job/queue_adapters/sucker_punch_adapter.rb
index 8191e5a1df..d721a0dcd5 100644
--- a/lib/active_job/queue_adapters/sucker_punch_adapter.rb
+++ b/lib/active_job/queue_adapters/sucker_punch_adapter.rb
@@ -1,12 +1,19 @@
require 'sucker_punch'
-require 'active_job/job_wrappers/sucker_punch_wrapper'
module ActiveJob
module QueueAdapters
class SuckerPunchAdapter
class << self
def queue(job, *args)
- JobWrappers::SuckerPunchWrapper.new.async.perform(job, *args)
+ JobWrapper.new.async.perform(job, *args)
+ end
+ end
+
+ class JobWrapper
+ include SuckerPunch::Job
+
+ def perform(job_name, *args)
+ job_name.perform(*ActiveJob::Parameters.deserialize(args))
end
end
end