From d7f6855ad86eda7249616a23bf5e2ed82835846a Mon Sep 17 00:00:00 2001 From: Carlos Antonio da Silva Date: Mon, 6 Mar 2017 17:33:34 -0300 Subject: [PATCH] Add some docs to the send email/password notification settings [ci skip] --- lib/devise/models/confirmable.rb | 4 +++- lib/devise/models/database_authenticatable.rb | 4 ++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/devise/models/confirmable.rb b/lib/devise/models/confirmable.rb index 9dea3933..f5ad5bce 100644 --- a/lib/devise/models/confirmable.rb +++ b/lib/devise/models/confirmable.rb @@ -26,7 +26,9 @@ module Devise # initial account confirmation) to be applied. Requires additional unconfirmed_email # db field to be set up (t.reconfirmable in migrations). Until confirmed, new email is # stored in unconfirmed email column, and copied to email column on successful - # confirmation. + # confirmation. Also, when used in conjunction with `send_email_change_notification`, + # the notification is sent to the original email when the change is requested, + # not when the unconfirmed email is confirmed. # * +confirm_within+: the time before a sent confirmation token becomes invalid. # You can use this to force the user to confirm within a set period of time. # Confirmable will not generate a new token if a repeat confirmation is requested diff --git a/lib/devise/models/database_authenticatable.rb b/lib/devise/models/database_authenticatable.rb index bda52134..7494a31b 100644 --- a/lib/devise/models/database_authenticatable.rb +++ b/lib/devise/models/database_authenticatable.rb @@ -14,6 +14,10 @@ module Devise # # * +stretches+: the cost given to bcrypt. # + # * +send_email_change_notification+: notify original email when it changes. + # + # * +send_password_change_notification+: notify email when password changes. + # # == Examples # # User.find(1).valid_password?('password123') # returns true/false