I have a middleware which gets applied in /something/:id and I have another controller with same method but the route is /something/somethingElse. The problem is the middleware is getting applied in both of the routes. How can I exclude it?
consumer
.apply(
AuthorizeMiddleWareCreator({
resourceType: permissions.SOMETHING
})
)
.forRoutes({ path: 'something/:id', method: RequestMethod.PUT });