Module: Patella::SendLater::ClassMethods

Defined in:
lib/patella/send_later.rb

Instance Method Summary collapse

Instance Method Details

#send_later(method_name, *args) ⇒ Object



17
18
19
20
21
22
23
# File 'lib/patella/send_later.rb', line 17

def send_later method_name, *args
  if Rails.caching?
    Patella::SendLaterWorker.perform_later self.to_s, nil, method_name, *args
  else
    self.send method_name, *args
  end
end