+1 on what @AdrianGaudebert said. 404 is a rather crappy code because in the mess of our middleware an empty result is easier to understand and work with.