Routes to ban, unban and edit user needed
Open
Backend
Easy
enhancement
KSoC’22
- Dominant language
- HTML
- Stars
- 9
- Forks
- 18
- PR merge metrics
- No merged PRs in 30d
Description
Two routes are to be created:
1. POST `/users/ban/{id}` - accessible only for admins. This route should take in user_id as params and update the user's status from verified to banned.
2. POST `/users/unban/{id}` - accessible only for admins. This route should take in user_id as params and update the user's status from banned to verified.
2. POST `users/update` - accessible for authorized users. This route will allow users to change their name, phone, address and username.
> Make sure you use POST instead of PUT as HTML forms do not support methods other than GET and POST.
Contributor guide
Assessment
This issue has not been assessed yet.