alphagov/whitehall — pull request #1090 by tekin (2013-11-26 09:51:30+00:00)
Title: 61203922 handle invalid json requests

This will get rid of the last major source of 500 errors on whitehall. By default, public-facing actions will only respond to html requests. Anything else will get a 404. Actions that need to respond to other formats need to explicitly enable them using the `enable_request_formats` helper.

For the Api controllers, We can simply skip the main filter that restricts requests, as these controllers use the `respond_to`/`respond_with` pattern to control/restrict format types.