Exception: HasOffersV3::InternalError

Inherits:
APIError show all
Defined in:
lib/hasoffersv3/api_error.rb

Instance Attribute Summary

Attributes inherited from ResponseError

#response

Class Method Summary collapse

Methods inherited from APIError

from_response

Methods inherited from ResponseError

#initialize

Constructor Details

This class inherits a constructor from HasOffersV3::ResponseError

Class Method Details

.detect(response) ⇒ Object



43
44
45
46
# File 'lib/hasoffersv3/api_error.rb', line 43

def self.detect(response)
  # E.g. "There was a database error with the trackable id [SE-5888e90b944af]. Contact support for more assistance."
  response.error_messages.grep(/error with the trackable id/).first
end