Exception: Rack::JsonSchema::ResponseValidation::InvalidResponseType

Inherits:
Error
  • Object
show all
Defined in:
lib/rack/json_schema/response_validation.rb

Instance Method Summary collapse

Methods inherited from Error

#to_rack_response

Constructor Details

#initialize(errors) ⇒ InvalidResponseType

Returns a new instance of InvalidResponseType.



129
130
131
# File 'lib/rack/json_schema/response_validation.rb', line 129

def initialize(errors)
  super ::JsonSchema::SchemaError.aggregate(errors).join(" ")
end

Instance Method Details

#idObject



133
134
135
# File 'lib/rack/json_schema/response_validation.rb', line 133

def id
  "invalid_response_type"
end

#statusObject



137
138
139
# File 'lib/rack/json_schema/response_validation.rb', line 137

def status
  500
end