I have two mailer procedures in the same app and same mailer (Rails
3.1/1.9.2). The first one fails with the message below, the second works
fine. Both these results are through irb. Anyone have an idea as to why?
Also, in my application.rb I do have: ActionMailer::Base.default :from =>
"WaveLineup <sys...@wavelineup.com>" defined.

FAILS
  def password_reset_instructions(user)
      @user = user
      @url = edit_password_reset_url(user.perishable_token)
      mail(:to => user.email, :subject => 'Password Reset for WaveLineup')
  end

  Error message:
  ruby-1.9.2-p290 :010 >
SystemMailer.password_reset_instructions(user).deliver
  ArgumentError: A sender (Return-Path, Sender or From) required to send a
message


WORKS FINE
  def wavelineup_invitation(invitation)
      @referring_user = invitation.referring_user
      @token = invitation.token
      mail(:to => invitation.email, :subject => 'Invitation to WaveLineup
Travel Card System for Network practitioners')
  end

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to