mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-10-31 02:55:58 +01:00 
			
		
		
		
	feat: #11420, add new GET routes to retrieve pending and invited members of a group, plus accept/reject pending
This commit is contained in:
		| @@ -47,3 +47,23 @@ Groups.rescind = async (req, res) => { | ||||
| 	await api.groups.rescind(req, req.params); | ||||
| 	helpers.formatApiResponse(200, res); | ||||
| }; | ||||
|  | ||||
| Groups.getPending = async (req, res) => { | ||||
| 	const pending = await api.groups.getPending(req, req.params); | ||||
| 	helpers.formatApiResponse(200, res, { pending }); | ||||
| }; | ||||
|  | ||||
| Groups.accept = async (req, res) => { | ||||
| 	await api.groups.accept(req, req.params); | ||||
| 	helpers.formatApiResponse(200, res); | ||||
| }; | ||||
|  | ||||
| Groups.reject = async (req, res) => { | ||||
| 	await api.groups.reject(req, req.params); | ||||
| 	helpers.formatApiResponse(200, res); | ||||
| }; | ||||
|  | ||||
| Groups.getInvites = async (req, res) => { | ||||
| 	const invites = await api.groups.getInvites(req, req.params); | ||||
| 	helpers.formatApiResponse(200, res, { invites }); | ||||
| }; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user