1
0
Fork 0
mirror of synced 2024-07-13 18:26:06 +12:00

fix roleId being undefined leading to groups override

This commit is contained in:
Peter Clement 2023-03-07 13:30:24 +00:00
parent 6acec42ae5
commit 1cb03c7603

View file

@ -35,8 +35,6 @@ export function updateAppRole(
user.roleId = roles.BUILTIN_ROLE_IDS.ADMIN
} else if (!user.roleId && !user?.userGroups?.length) {
user.roleId = roles.BUILTIN_ROLE_IDS.PUBLIC
} else if (user?.userGroups?.length) {
user.roleId = undefined
}
delete user.roles