Class: PhraseApp::RequestErrors::ValidationErrorResponse

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(http_response) ⇒ ValidationErrorResponse

Returns a new instance of ValidationErrorResponse.



23
24
25
26
# File 'lib/request_handler.rb', line 23

def initialize(http_response)
  hash = JSON.load(http_response.body)
  puts hash.inspect
end

Instance Attribute Details

#error_responseObject

Returns the value of attribute error_response.



20
21
22
# File 'lib/request_handler.rb', line 20

def error_response
  @error_response
end

#errorsObject

Returns the value of attribute errors.



21
22
23
# File 'lib/request_handler.rb', line 21

def errors
  @errors
end