Skip to content

Commit 911341c

Browse files
authored
fix: navconfig permission function (#555)
1 parent d20d074 commit 911341c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/utils/permission.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ import { GetSessionApiResponse } from 'redux/otomiApi'
44
export function canDo(user: GetSessionApiResponse['user'], teamId: string, action: string): boolean {
55
if (user.isPlatformAdmin) return true
66
if (!teamId) return false
7-
const deniedActions = get(user, `authz.${teamId}.deniedAttributes.access`, [])
7+
const deniedActions = get(user, `authz.${teamId}.deniedAttributes.teamMembers`, [])
88
return !deniedActions.includes(action)
99
}

0 commit comments

Comments
 (0)