Exception: PosthavenTheme::APIError

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ APIError

Returns a new instance of APIError.



14
15
16
# File 'lib/posthaven_theme.rb', line 14

def initialize(response)
  @response = response
end

Instance Attribute Details

#responseObject

Returns the value of attribute response.



12
13
14
# File 'lib/posthaven_theme.rb', line 12

def response
  @response
end

Instance Method Details

#messageObject



18
19
20
# File 'lib/posthaven_theme.rb', line 18

def message
  "#{response_message} – #{response_error_message(response)}"
end