Exception: JSONAPI::Exceptions::SaveFailed

Inherits:
Error
  • Object
show all
Defined in:
lib/jsonapi/exceptions.rb

Instance Attribute Summary

Attributes inherited from Error

#error_object_overrides

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

#errorsObject



531
532
533
534
535
536
537
538
# File 'lib/jsonapi/exceptions.rb', line 531

def errors
  [create_error_object(code: JSONAPI::SAVE_FAILED,
                       status: :unprocessable_entity,
                       title: I18n.translate('jsonapi-resources.exceptions.save_failed.title',
                                             default: 'Save failed or was cancelled'),
                       detail: I18n.translate('jsonapi-resources.exceptions.save_failed.detail',
                                              default: 'Save failed or was cancelled'))]
end