title: Sending 405 from express.js when there is a route match but no HTTP method match
body: <p>I'm looking for a clean way to have my express app return 405 Method Not Allowed if a client sends a request that matches a mapped url route but does not match the mapped HTTP method. </p>
  
  <p>My current implementation is to have a default "catch-all" handler that tries to match the url against the register routes, ignoring the HTTP method. If there is a match, then we know to return a 405, otherwise we let express do its default 404 behavior.</p>
  
  <p>I'm hoping there is a better way that doesn't involve running all the route matching twice (once by express, once by my handler).</p>