Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API Make Admin and Remove Admin #33

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

Signior-X
Copy link
Member

Fixes #11
I have created the API, which firsts check if the logined user is an admin or not, then updates the values in the Users table, making him admin or removing them.
It accepts the userID of the user, and checks if it exists, is an admin or not, and make him an admin or emove it. Two different functions for each task.

@karanankit01
Copy link
Collaborator

Your PR is alright, but I think we can store the admin status in session itself
We can refactor this PR after that and merge

@Signior-X
Copy link
Member Author

yes, you are right, I will edit it, and also ensure that the PR of login will also add the admin information in the admin. Thanks,
By the way, what is the meaning of refractor this PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

API : Make admin
2 participants