Exception: Tikkie::Api::AuthenticationException

Inherits:
Exception
  • Object
show all
Defined in:
lib/tikkie/api/exception.rb

Overview

Exception when the authentication fails.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ AuthenticationException

Returns a new instance of AuthenticationException.



13
14
15
16
17
18
19
# File 'lib/tikkie/api/exception.rb', line 13

def initialize(response)
  @response = response
  @body = response.body

  message = "Authentication failure at Tikkie"
  super(message)
end

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



11
12
13
# File 'lib/tikkie/api/exception.rb', line 11

def body
  @body
end

#responseObject (readonly)

Returns the value of attribute response.



11
12
13
# File 'lib/tikkie/api/exception.rb', line 11

def response
  @response
end