Implemented Router Middleware