Method: Lines::User.digest
- Defined in:
- app/models/lines/user.rb
.digest(string) ⇒ Object
Returns the hash digest of the given string.
54 55 56 57 |
# File 'app/models/lines/user.rb', line 54 def User.digest(string) cost = ActiveModel::SecurePassword.min_cost ? BCrypt::Engine::MIN_COST : BCrypt::Engine.cost BCrypt::Password.create(string, cost: cost) end |