Exception: Kentaa::Api::RequestError

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ RequestError

Returns a new instance of RequestError.



11
12
13
14
15
# File 'lib/kentaa/api/exception.rb', line 11

def initialize(response)
  @response = response

  super(response.message)
end

Instance Attribute Details

#responseObject

Returns the value of attribute response.



9
10
11
# File 'lib/kentaa/api/exception.rb', line 9

def response
  @response
end

Instance Method Details

#http_codeObject



17
18
19
# File 'lib/kentaa/api/exception.rb', line 17

def http_code
  response.http_code
end