Sha256: 0bed36099d19daad1d12bb2abaf06ca043d902c542246cc0810af807f4c77c85
Contents?: true
Size: 597 Bytes
Versions: 1
Compression:
Stored size: 597 Bytes
Contents
module Clearance class Configuration attr_accessor \ :cookie_expiration, :mailer_sender, :password_strategy, :redirect_url, :secure_cookie, :user_model def initialize @cookie_expiration = lambda { 1.year.from_now.utc } @mailer_sender = 'reply@example.com' @secure_cookie = false @redirect_url = '/' end def user_model @user_model || ::User end end class << self attr_accessor :configuration end def self.configure self.configuration ||= Configuration.new yield configuration end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
clearance-1.0.0.rc7 | lib/clearance/configuration.rb |