unconfirmed_email now uses the proper e-mail on salutation, related to #2060

This commit is contained in:
José Valim 2012-12-13 08:53:23 +01:00
parent e1fde192f2
commit 4c83743263
5 changed files with 5 additions and 4 deletions

View File

@ -10,6 +10,7 @@
* Support alternate sign in error message when email record does not exist (@gabetax)
* bug fix
* unconfirmed_email now uses the proper e-mail on salutation
* Fix default email_regexp config to not allow spaces (by @kukula)
* Fix a regression introduced on warden 1.2.1 (by @ejfinneran)
* Properly camelize omniauth strategies (by @saizai)

View File

@ -1,4 +1,4 @@
<p>Welcome <%= @resource.email %>!</p>
<p>Welcome <%= @headers[:to] %>!</p>
<p>You can confirm your account email through the link below:</p>

View File

@ -38,7 +38,7 @@ module Devise
headers.merge!(resource.headers_for(action))
end
headers
@headers = headers
end
def mailer_reply_to(mapping)

View File

@ -1,4 +1,4 @@
Welcome <%= @resource.email %>!
Welcome <%= @headers[:to] %>!
You can confirm your account through the link below:

View File

@ -294,7 +294,6 @@ class ReconfirmableTest < ActiveSupport::TestCase
assert_nil admin.confirmation_token
end
test 'should regenerate confirmation token after changing email' do
admin = create_admin
assert admin.confirm!
@ -310,6 +309,7 @@ class ReconfirmableTest < ActiveSupport::TestCase
assert_email_sent "new_test@example.com" do
assert admin.update_attributes(:email => 'new_test@example.com')
end
assert_match "new_test@example.com", ActionMailer::Base.deliveries.last.body.encoded
end
test 'should not send confirmation by email after changing password' do