Well, I'm concerned about the architecture here, and it does not seem intuitive to me to have the router need access to the middleware stack, it should be the other way around.