Right now when params don't match, we're falling through to the next route handler (and eventually sending a 404 if nothing "matches"). This is a reasonable thing to do for non-matching URL params (e.g. an Int :id when we're expecting a String).
However, it's arguably a bit strange to send a 404 when you POST some params in the body, but you're missing a required param. The route isn't actually 404, it's just a 400 bad request.
Right now when params don't match, we're falling through to the next route handler (and eventually sending a 404 if nothing "matches"). This is a reasonable thing to do for non-matching URL params (e.g. an Int
:id
when we're expecting a String).However, it's arguably a bit strange to send a 404 when you POST some params in the body, but you're missing a required param. The route isn't actually 404, it's just a 400 bad request.