Add documentation to the 'after_database_authentication' method.

This commit is contained in:
Dave Tong 2013-10-24 08:15:53 +11:00
parent fb530110c7
commit 8bef8b87f1
1 changed files with 11 additions and 1 deletions

View File

@ -101,7 +101,7 @@ module Devise
end
# Destroy record when :current_password matches, otherwise returns
# error on :current_password. It also automatically rejects
# error on :current_password. It also automatically rejects
# :current_password if it is blank.
def destroy_with_password(current_password)
result = if valid_password?(current_password)
@ -115,6 +115,16 @@ module Devise
result
end
# A callback initiated after successfully authenticating. This can be
# used to insert your own logic that is only run after the user successfully
# authenticates.
#
# Example:
#
# def after_database_authentication
# self.update_attribute(:invite_code, nil)
# end
#
def after_database_authentication
end