1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-25 00:07:47 +01:00

Update src/lib/services/project-service.ts

Co-authored-by: Fredrik Strand Oseberg <fredrik.no@gmail.com>
This commit is contained in:
Ivar Conradi Østhus 2022-02-24 14:59:01 +01:00
parent 2f189db394
commit 017bd75c9c

View File

@ -365,7 +365,7 @@ export default class ProjectService {
const usersWithRoles = await this.getUsersWithAccess(projectId);
const user = usersWithRoles.users.find((user) => user.id === userId);
const currentRole = usersWithRoles.roles.find(
(r) => r.id === user.roleId,
(role) => role.id === user.roleId,
);
if (currentRole.id === roleId) {