class Esi::ApiRequestError
ApiRequestError
Class @!attribute [r] original_exception
@return [ExceptionClass|nil] the orginal raised exception
Attributes
original_exception[R]
Public Class Methods
new(original_exception)
click to toggle source
Create a new instance of ApiRequestError
@param original_exception
[ExceptionClass|nil] the orginally raised exception @return [Esi::ApiRequestError] the instance of ApiRequestError
Calls superclass method
# File lib/esi/api_error.rb, line 43 def initialize(original_exception) @original_exception = original_exception msg = "#{original_exception.class}: " \ "#{original_exception.try(:response).try(:status)}" \ ' - ' \ "#{original_exception.try(:message)}" super(msg) end