Exception: Rasti::App::Policy::UnauthorizedError
- Inherits:
-
StandardError
- Object
- StandardError
- Rasti::App::Policy::UnauthorizedError
- Defined in:
- lib/rasti/app/policy.rb
Instance Attribute Summary collapse
-
#permission ⇒ Object
readonly
Returns the value of attribute permission.
-
#user ⇒ Object
readonly
Returns the value of attribute user.
Instance Method Summary collapse
-
#initialize(user, permission) ⇒ UnauthorizedError
constructor
A new instance of UnauthorizedError.
- #message ⇒ Object
Constructor Details
#initialize(user, permission) ⇒ UnauthorizedError
Returns a new instance of UnauthorizedError.
9 10 11 12 |
# File 'lib/rasti/app/policy.rb', line 9 def initialize(user, ) @user = user @permission = end |
Instance Attribute Details
#permission ⇒ Object (readonly)
Returns the value of attribute permission.
7 8 9 |
# File 'lib/rasti/app/policy.rb', line 7 def @permission end |
#user ⇒ Object (readonly)
Returns the value of attribute user.
7 8 9 |
# File 'lib/rasti/app/policy.rb', line 7 def user @user end |
Instance Method Details
#message ⇒ Object
14 15 16 |
# File 'lib/rasti/app/policy.rb', line 14 def "Permission denied [#{user} -> #{}]" end |