Exception: Authz::Controllers::AuthorizationManager::AuthorizationNotPerformedError
- Inherits:
-
StandardError
- Object
- StandardError
- Authz::Controllers::AuthorizationManager::AuthorizationNotPerformedError
- Defined in:
- lib/authz/controllers/authorization_manager.rb
Overview
Error that will be raised if a controller action has not called the ‘authorize` or `skip_authorization` methods.
Instance Attribute Summary collapse
- #action ⇒ Object readonly
- #controller ⇒ Object readonly
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ AuthorizationNotPerformedError
constructor
A new instance of AuthorizationNotPerformedError.
Constructor Details
#initialize(options = {}) ⇒ AuthorizationNotPerformedError
Returns a new instance of AuthorizationNotPerformedError.
17 18 19 20 21 22 |
# File 'lib/authz/controllers/authorization_manager.rb', line 17 def initialize( = {}) @controller = .fetch :controller @action = .fetch :action msg = "#{controller}##{action} is missing authorization." super(msg) end |
Instance Attribute Details
#action ⇒ Object (readonly)
16 17 18 |
# File 'lib/authz/controllers/authorization_manager.rb', line 16 def action @action end |
#controller ⇒ Object (readonly)
16 17 18 |
# File 'lib/authz/controllers/authorization_manager.rb', line 16 def controller @controller end |