diff --git a/src/routes/write/groups.js b/src/routes/write/groups.js index 00cfb5f22631..0a93266e8f38 100644 --- a/src/routes/write/groups.js +++ b/src/routes/write/groups.js @@ -11,9 +11,9 @@ module.exports = function () { const middlewares = [middleware.authenticate]; setupApiRoute(router, '/', middleware, [...middlewares, middleware.checkRequired.bind(null, ['name'])], 'post', controllers.write.groups.create); - setupApiRoute(router, '/:slug', middleware, [...middlewares, middleware.assert.group, middleware.exposePrivileges], 'delete', controllers.write.groups.delete); - setupApiRoute(router, '/:slug/membership/:uid', middleware, [...middlewares, middleware.assert.group, middleware.exposePrivileges], 'put', controllers.write.groups.join); - setupApiRoute(router, '/:slug/membership/:uid', middleware, [...middlewares, middleware.assert.group, middleware.exposePrivileges], 'delete', controllers.write.groups.leave); + setupApiRoute(router, '/:slug', middleware, [...middlewares, middleware.assert.group], 'delete', controllers.write.groups.delete); + setupApiRoute(router, '/:slug/membership/:uid', middleware, [...middlewares, middleware.assert.group], 'put', controllers.write.groups.join); + setupApiRoute(router, '/:slug/membership/:uid', middleware, [...middlewares, middleware.assert.group], 'delete', controllers.write.groups.leave); return router; };