mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
e62e68e25b
Since we have `has_secure_token`, it is too confusing to use `_token` suffix with `has_secure_password`. Context https://github.com/rails/rails/pull/33307#discussion_r200807185
13 lines
295 B
Ruby
13 lines
295 B
Ruby
# frozen_string_literal: true
|
|
|
|
class User
|
|
extend ActiveModel::Callbacks
|
|
include ActiveModel::SecurePassword
|
|
|
|
define_model_callbacks :create
|
|
|
|
has_secure_password
|
|
has_secure_password :recovery_password, validations: false
|
|
|
|
attr_accessor :password_digest, :recovery_password_digest
|
|
end
|