I’ve got a RESTful resource (let’s say posts) that excludes the index action. When I go to /posts, ActionController::MethodNotAllowed is raised because GET requests at that URL have been excluded. That much makes sense.
The problem is that in the production environment, that URL just generates a white screen in the browser. I can see ActionController::MethodNotAllowed being raised in the production log. I would expect that this would also cause a 404 or 500 error so that the error pages in the public directory would serve a pretty error page to the client.
Does this cause a different HTTP status code? How can I handle this?
I’m not positive about what the error might be, but you should get Firebug and check what the HTTP response code coming back is.
To get around the issue, you could do one of two things:
GET /posts, which points to your desired controller.