1
0
Fork 0
mirror of https://github.com/heartcombo/devise.git synced 2022-11-09 12:18:31 -05:00
heartcombo--devise/test/rails_app/lib/shared_admin.rb

17 lines
565 B
Ruby

module SharedAdmin
extend ActiveSupport::Concern
included do
devise :database_authenticatable, :registerable,
:timeoutable, :recoverable, :lockable, :confirmable,
:unlock_strategy => :time, :lock_strategy => :none,
:allow_unconfirmed_access_for => 2.weeks, :reconfirmable => true
validates_length_of :reset_password_token, :minimum => 3, :allow_blank => true
validates_uniqueness_of :email, :allow_blank => true, :if => :email_changed?
end
def raw_confirmation_token
@raw_confirmation_token
end
end