Class: Moon::Response::JSON::ValidationErrors

Inherits:
Moon::Response::JSON show all
Defined in:
lib/moon/response/json/validation_errors.rb

Overview

Moon::Response::JSON::ValidationErrors provides a simple response with the validation messages

Instance Attribute Summary

Attributes inherited from Moon::Response::JSON

#hash, #status

Instance Method Summary collapse

Methods inherited from Moon::Response::JSON

#body, #headers

Methods inherited from Base

#body, #headers, #status

Constructor Details

#initialize(validation_errors) ⇒ ValidationErrors

Returns a new instance of ValidationErrors.



5
6
7
# File 'lib/moon/response/json/validation_errors.rb', line 5

def initialize(validation_errors)
  super 200, :validation_errors => validation_errors
end