jsonapi-utils
jsonapi-utils copied to clipboard
Formatting of error's "detail" attribute
If rails-i18n gem is used, the formatting of detail member of error object https://github.com/tiagopog/jsonapi-utils/blob/a2c2b0e3843376718929723d9f609611f68b665e/lib/jsonapi/utils/exceptions/active_record.rb#L151
should reflect locale's configuration:
I18n.t('errors.format', attribute: translation_for(resource_key), message: message)