Module: BufferedJob::Ext
- Defined in:
- lib/buffered_job/ext.rb
Instance Method Summary collapse
Instance Method Details
#buffer(key = nil, opt = {}) ⇒ Object
7 8 9 10 11 12 13 14 15 |
# File 'lib/buffered_job/ext.rb', line 7 def buffer(key=nil,opt={}) if !self.respond_to?(:id) and self.superclass != ActionMailer::Base raise NoBufferTargetError end if self.kind_of?(Class) and key.nil? raise NoBufferKeywordError,"Specify buffer keyword like YourMailer.buffer('send_to_user/123').notification(msg)" end buffer_for(self,key,opt) end |