Method: Oath::Configuration#default_hashing_method

Defined in:
lib/oath/configuration.rb

#default_hashing_methodObject

Default hashing method. Can be overriden via Oath.configure

See Also:

Since:

  • 0.0.15



41
42
43
44
45
46
47
48
49
# File 'lib/oath/configuration.rb', line 41

def default_hashing_method
  ->(token) do
    if token.present?
      BCrypt::Password.create(token)
    else
      token
    end
  end
end