Exception: Authz::Scopables::Base::NoApplicableScopables
- Inherits:
-
StandardError
- Object
- StandardError
- Authz::Scopables::Base::NoApplicableScopables
- Defined in:
- lib/authz/scopables/base.rb
Overview
Raised when the scoping system is used on an instance of a class that has no applicable scopables
Instance Attribute Summary collapse
- #scoped_class ⇒ Object readonly
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ NoApplicableScopables
constructor
A new instance of NoApplicableScopables.
Constructor Details
#initialize(options = {}) ⇒ NoApplicableScopables
Returns a new instance of NoApplicableScopables.
131 132 133 134 135 136 137 |
# File 'lib/authz/scopables/base.rb', line 131 def initialize( = {}) @scoped_class = .fetch(:scoped_class) = "#{scoped_class} has no applicable scopables. " \ 'Make sure you include the scopables modules ' \ 'inside the class definition.' super() end |
Instance Attribute Details
#scoped_class ⇒ Object (readonly)
129 130 131 |
# File 'lib/authz/scopables/base.rb', line 129 def scoped_class @scoped_class end |