Permalink
Browse files

Mailer should give self as payload because it contains all the inform…

…ation needed (as the template rendered and the mailer name).
  • Loading branch information...
1 parent 7045c4c commit 802b08da0075bf6426c723957447ed85dc849bba @josevalim josevalim committed Jan 8, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 actionmailer/lib/action_mailer/base.rb
@@ -499,7 +499,7 @@ def deliver!(mail = @mail)
logger.debug "\n#{mail.encoded}"
end
- ActiveSupport::Notifications.instrument("action_mailer.deliver", :mail => mail) do
+ ActiveSupport::Notifications.instrument("action_mailer.deliver", :mail => self) do
begin
self.delivery_method.perform_delivery(mail) if perform_deliveries
rescue Exception => e # Net::SMTP errors or sendmail pipe errors

0 comments on commit 802b08d

Please sign in to comment.