Sha256: 91ef2efdb2b55c1774d692f39ae13261a217151946e3d1d801c3d1d9f0bef6ec
Contents?: true
Size: 571 Bytes
Versions: 2
Compression:
Stored size: 571 Bytes
Contents
module AuthStrategist class Configuration attr_accessor :default_strategy_components, :strategies_path def initialize @default_strategy_components = [] @strategies = strategies_registry_class.new end def strategies return @strategies unless block_given? load_strategies yield(@strategies) end private def load_strategies Dir["./#{strategies_path}/*.rb"].each { |file| require file } if strategies_path end def strategies_registry_class self.class::StrategiesRegistry end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
auth_strategist-0.6.0 | lib/auth_strategist/configuration.rb |
auth_strategist-0.5.0 | lib/auth_strategist/configuration.rb |