grape

https://github.com/intridea/grape

Ruby

An opinionated framework for creating REST-like APIs in Ruby.

Grape::Exceptions::Validation#as_json

remove all the unnecessary stuff from Grape::Exceptions::Base like status
and headers when converting a validation error to json or string

Source | Google | Stack overflow

Edit

git clone [email protected]:intridea/grape.git

cd grape

open lib/grape/exceptions/validation.rb

Contribute

# Make a new branch

git checkout -b -your-name--update-docs-Grape--Exceptions--Validation-as_json-for-pr


# Commit to git

git add lib/grape/exceptions/validation.rbgit commit -m "better docs for Grape::Exceptions::Validation#as_json"


# Open pull request

gem install hub # on a mac you can `brew install hub`

hub fork

git push <your name> -your-name--update-docs-Grape--Exceptions--Validation-as_json-for-pr

hub pull-request


# Celebrate!