Closed Subham142 closed 3 years ago
Hi 😄, thanks for creating your first issue at GURUJII, do read and follow the Contribution Guidelines while contributing. Someone from our team will get back here soon.
@Namanl2001 please assign it to me
Sorry, but I didn't get it. Could you explain it a bit more in detail? Thanks
its basically means I wanna add an admin feature to this project
the admin can
-> fetch all the users, edit their profile, delete users
->fetch all the teachers, edit their profile, delete users
In this issue, I want to add an admin middleware so that if the user is logged in and is an admin he/she could access the admin routes (which will be added after the middleware is done) -> to know if the user is admin or not we need to add an extra argument to the userSchema of isAdmin
Sounds Good. Please go ahead! 👍
Describe the feature you'd like to add add admin feature by adding middleware and updating the user schema