Exception: JSONAPI::Exceptions::InvalidDataFormat
- Defined in:
- lib/jsonapi/exceptions.rb
Instance Attribute Summary
Attributes inherited from Error
Instance Method Summary collapse
Methods inherited from Error
#create_error_object, #initialize
Constructor Details
This class inherits a constructor from JSONAPI::Exceptions::Error
Instance Method Details
#errors ⇒ Object
271 272 273 274 275 276 277 278 |
# File 'lib/jsonapi/exceptions.rb', line 271 def errors [create_error_object(code: JSONAPI::INVALID_DATA_FORMAT, status: :bad_request, title: I18n.translate('jsonapi-resources.exceptions.invalid_data_format.title', default: 'Invalid data format'), detail: I18n.translate('jsonapi-resources.exceptions.invalid_data_format.detail', default: 'Data must be a hash.'))] end |