Exception: AeriesApi::ResponseError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/aeries-api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ ResponseError

Returns a new instance of ResponseError.



9
10
11
12
13
# File 'lib/aeries-api.rb', line 9

def initialize(response)
  message = response.parsed_response['Message']
  super(message.length <= 50 ? message[0..50] : message)
  @response = response
end

Instance Attribute Details

#responseObject

Returns the value of attribute response.



7
8
9
# File 'lib/aeries-api.rb', line 7

def response
  @response
end