Exception: WebPay::ErrorResponse::ApiError

Inherits:
ErrorResponseError show all
Defined in:
lib/webpay/error.rb

Instance Attribute Summary

Attributes inherited from ErrorResponseError

#data, #status

Instance Method Summary collapse

Constructor Details

#initialize(status, raw_data) ⇒ ApiError

Returns a new instance of ApiError.



66
67
68
69
70
# File 'lib/webpay/error.rb', line 66

def initialize(status, raw_data)
  data = WebPay::ErrorData.new(raw_data)
  message = sprintf('%s: %s', 'ApiError', data.error.message)
  super(message, status, data)
end