Exception: Leash::AuthError
- Defined in:
- lib/leash/errors.rb
Overview
Raised by ‘Leash::Auth.get_user` when the leash-auth cookie is missing / invalid. `Leash#auth.user` returns `nil` instead so it never raises.
Instance Attribute Summary
Attributes inherited from Error
#action, #cause, #code, #see_also, #status
Instance Method Summary collapse
-
#initialize(message = "Authentication failed", **opts) ⇒ AuthError
constructor
A new instance of AuthError.
Methods inherited from Error
Constructor Details
#initialize(message = "Authentication failed", **opts) ⇒ AuthError
Returns a new instance of AuthError.
121 122 123 124 |
# File 'lib/leash/errors.rb', line 121 def initialize( = "Authentication failed", **opts) opts[:code] ||= "NO_AUTH_CONTEXT" super(, **opts) end |