Exception: InfusionAPIError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/infusionsoft/connection.rb

Overview

Extend StandardError to keep track of Error being wrapped Pattern from Exceptional Ruby by Avdi Grimm (avdi.org/talks/exceptional-ruby-2011-02-04/)

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(msg, original = nil) ⇒ InfusionAPIError



47
48
49
50
51
# File 'lib/infusionsoft/connection.rb', line 47

def initialize(msg, original=nil);
  api_logger.error "ERROR: #{msg}"
  super(msg);
  @original = original;
end

Instance Attribute Details

#originalObject (readonly)

Returns the value of attribute original.



46
47
48
# File 'lib/infusionsoft/connection.rb', line 46

def original
  @original
end