Instruct Grape to handle Validation errors

See ca0edb1a.

Signed-off-by: Alex Coles <alex@alexbcoles.com>
pull/1655/head
Alex Coles 10 years ago
parent 2f16aeae6e
commit dd0dc65753
  1. 2
      lib/api/root.rb

@ -70,7 +70,7 @@ module API
Rack::Response.new(error.to_json, error.code, error.headers).finish
end
rescue_from API::Errors::Unauthorized, API::Errors::Unauthenticated do |e|
rescue_from API::Errors::Unauthorized, API::Errors::Unauthenticated, API::Errors::Validation do |e|
Rack::Response.new(e.to_json, e.code, e.headers).finish
end

Loading…
Cancel
Save