Exception: AmexEnhancedAuthorization::Request::UnexpectedHttpResponse

Inherits:
StandardError
  • Object
show all
Defined in:
lib/amex_enhanced_authorization/request.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ UnexpectedHttpResponse

Returns a new instance of UnexpectedHttpResponse.



35
36
37
38
# File 'lib/amex_enhanced_authorization/request.rb', line 35

def initialize(response)
  @response = response
  super "#{response.message} (#{response.code}): #{response.body}"
end

Instance Attribute Details

#responseObject (readonly)

Returns the value of attribute response.



33
34
35
# File 'lib/amex_enhanced_authorization/request.rb', line 33

def response
  @response
end