Exception: CardDB::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/carddb/errors.rb

Overview

Base error class for all CardDB errors

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message = nil, response: nil) ⇒ Error

Returns a new instance of Error.



9
10
11
12
# File 'lib/carddb/errors.rb', line 9

def initialize(message = nil, response: nil)
  @response = response
  super(message)
end

Instance Attribute Details

#responseHash? (readonly)

Returns The full response body if available.

Returns:

  • (Hash, nil)

    The full response body if available



7
8
9
# File 'lib/carddb/errors.rb', line 7

def response
  @response
end