mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-02-13 10:07:33 +01:00
isInvited mechanic for #2758
This commit is contained in:
@@ -42,7 +42,12 @@ groupsController.details = function(req, res, next) {
|
||||
next(null, true);
|
||||
} else {
|
||||
// If not, only members are granted access
|
||||
groups.isMember(uid, res.locals.groupName, next);
|
||||
async.parallel([
|
||||
async.apply(groups.isMember, uid, res.locals.groupName),
|
||||
async.apply(groups.isInvited, uid, res.locals.groupName)
|
||||
], function(err, checks) {
|
||||
next(err, checks[0] || checks[1]);
|
||||
});
|
||||
}
|
||||
}
|
||||
], function(err, ok) {
|
||||
|
||||
Reference in New Issue
Block a user