Javascript – getting error that .include() is not a function, even though i passed an array
I am trying to write a middleware that checks if the user that is trying to retrieve the data of all users is an admin or not, for testing purpose I have manually passed an array to isAuthorized function. userRouter.use(isAuthorized(['admin']));…