Sha256: 51058c6bf2a2ecc65b21a90ae2c312ff9767b579b4c27c19c9ed27c474c993a9
Contents?: true
Size: 892 Bytes
Versions: 1
Compression:
Stored size: 892 Bytes
Contents
module Authority class Configuration # Has default settings, overrideable in the initializer. attr_accessor :default_strategy, :abilities, :controller_action_map, :user_method, :security_violation_handler, :logger def initialize @default_strategy = Proc.new do |able, authorizer, user| false end @abilities = { :create => 'creatable', :read => 'readable', :update => 'updatable', :delete => 'deletable' } @controller_action_map = { :index => 'read', :show => 'read', :new => 'create', :create => 'create', :edit => 'update', :update => 'update', :destroy => 'delete' } @user_method = :current_user @security_violation_handler = :authority_forbidden @logger = Logger.new(STDERR) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
authority-1.0.0 | lib/authority/configuration.rb |