Class: ResqueFailedJobMailer::Mailer
- Inherits:
-
ActionMailer::Base
- Object
- ActionMailer::Base
- ResqueFailedJobMailer::Mailer
- Defined in:
- lib/resque_failed_job_mailer/mailer.rb
Instance Method Summary collapse
Instance Method Details
#alert(notifier) ⇒ Object
3 4 5 6 7 8 9 10 11 |
# File 'lib/resque_failed_job_mailer/mailer.rb', line 3 def alert notifier @notifier = notifier text = ERB.new(File.read(File.dirname(__FILE__) + "/alert.html.erb")).result(binding) = Resque::Failure::Notifier. subject = "[#{.join('][')}] #{@notifier.exception}" mail :from => Resque::Failure::Notifier.from, :to => Resque::Failure::Notifier.to, :subject => subject do |format| format.html { render :text => text } end end |