Skip to content

Instantly share code, notes, and snippets.

@tammersaleh
Created October 19, 2010 21:28
Show Gist options
  • Select an option

  • Save tammersaleh/635161 to your computer and use it in GitHub Desktop.

Select an option

Save tammersaleh/635161 to your computer and use it in GitHub Desktop.
class Mailer < ActionMailer::Base
default :from => "[email protected]"
helper :formatting
def new_notification(user)
@idea = idea
@user = user
headers("X-Foo" => "foo")
mail :to => user.email,
:subject => "Subject",
"X-Bar" => "foo"
end
end
email = Mailer.new_notification(user)
p email.headers # => {} WTF??
email.deliver
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment