Exception: Delighted::Error

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

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ Error

Returns a new instance of Error.


3
4
5
# File 'lib/delighted/errors.rb', line 3

def initialize(response)
  @response = response
end

Instance Method Details

#to_sObject


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

def to_s
  "#{@response.status_code}: #{@response.body}"
end