The route not found handler should not be a acquired from a function call, it should instead of a property of the router, which we can apply middleware to as they are being enabled. This will help simplify the middleware enabling logic and also help with adding custom route not found handlers.
Description
The
route not found handler
should not be a acquired from a function call, it should instead of a property of the router, which we can apply middleware to as they are being enabled. This will help simplify the middleware enabling logic and also help with adding custom route not found handlers.