Module: Laters::Concern
- Extended by:
- ActiveSupport::Concern
- Includes:
- ActiveModel::Callbacks
- Defined in:
- lib/laters/concern.rb
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object (private)
22 23 24 25 26 27 28 29 30 |
# File 'lib/laters/concern.rb', line 22 def method_missing(method, *args, &block) if (method_to_call = deferrable_method_name(method)) InstanceMethodJob .set(queue: self.class.job_queue || :default) .perform_later(self, method_to_call, *args) else super end end |