diff options
author | David Heinemeier Hansson <david@basecamp.com> | 2014-07-28 20:33:03 -0700 |
---|---|---|
committer | David Heinemeier Hansson <david@basecamp.com> | 2014-07-28 20:33:03 -0700 |
commit | 63f92c0205ee3abcbc299c000f62d3caffc61323 (patch) | |
tree | ac3f4a9197be8df5b17a4e2014720b50e288d463 | |
parent | 2c31b1832f440d0eb7c5db51d11630e885d0a824 (diff) | |
parent | 21730dea6b5e5bb4bdb3420ae31238ee94925a0a (diff) | |
download | rails-63f92c0205ee3abcbc299c000f62d3caffc61323.tar.gz rails-63f92c0205ee3abcbc299c000f62d3caffc61323.tar.bz2 rails-63f92c0205ee3abcbc299c000f62d3caffc61323.zip |
Merge pull request #100 from timriley/fix-que-class-serialization
Fix database serialization of job class names with Que
-rw-r--r-- | lib/active_job/queue_adapters/que_adapter.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/active_job/queue_adapters/que_adapter.rb b/lib/active_job/queue_adapters/que_adapter.rb index 3d30b2bc72..4af3a0fbcf 100644 --- a/lib/active_job/queue_adapters/que_adapter.rb +++ b/lib/active_job/queue_adapters/que_adapter.rb @@ -5,7 +5,7 @@ module ActiveJob class QueAdapter class << self def enqueue(job, *args) - JobWrapper.enqueue job, *args, queue: job.queue_name + JobWrapper.enqueue job.to_s, *args, queue: job.queue_name end def enqueue_at(job, timestamp, *args) @@ -15,7 +15,7 @@ module ActiveJob class JobWrapper < Que::Job def run(job, *args) - job.new.execute *args + job.constantize.new.execute *args end end end |