Commit 949d7b4c authored by Varunkumar Manohar's avatar Varunkumar Manohar
Browse files

Add viewer groups to the subproject service groups list if present

parent d013f831
Pipeline #44195 passed with stages
in 10 minutes and 32 seconds
......@@ -83,7 +83,11 @@ export class UserHandler {
const subproject = await SubProjectDAO.get(journalClient, tenant.name, sdPath.subproject, spkey);
const serviceGroupRegex = SubprojectGroups.serviceGroupNameRegExp(tenant.name, subproject.name);
const subprojectServiceGroups = subproject.acls.admins.filter((group) => group.match(serviceGroupRegex));
const subprojectAdminServiceGroups = subproject.acls.admins
.filter((group) => group.match(serviceGroupRegex));
const subprojectViewerServiceGroups = subproject.acls.viewers
.filter((group) => group.match(serviceGroupRegex));
const subprojectServiceGroups = subprojectAdminServiceGroups.concat(subprojectViewerServiceGroups);
const dataGroupRegex = SubprojectGroups.dataGroupNameRegExp(tenant.name, subproject.name);
const adminSubprojectDataGroups = subproject.acls.admins.filter((group) => group.match(dataGroupRegex));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment