Class: Apress::Api::EventHandlerEnqueueingJob
- Inherits:
-
Object
- Object
- Apress::Api::EventHandlerEnqueueingJob
- Includes:
- Resque::Integration
- Defined in:
- app/jobs/apress/api/event_handler_enqueueing_job.rb
Class Method Summary collapse
Class Method Details
.perform(handler, event_params) ⇒ Object
9 10 11 12 13 14 15 16 17 |
# File 'app/jobs/apress/api/event_handler_enqueueing_job.rb', line 9 def self.perform(handler, event_params) job = handler.camelize.constantize if job.respond_to?(:enqueue) job.enqueue(event_params) else Resque.enqueue(job, event_params) end end |