mirror of
https://github.com/umami-software/umami.git
synced 2026-02-04 04:37:11 +01:00
check for explicit teamCreate permissions for global role in canCreateTeam
This commit is contained in:
parent
8b2196b97a
commit
a1efb2d86a
1 changed files with 1 additions and 1 deletions
|
|
@ -16,7 +16,7 @@ export async function canCreateTeam({ user }: Auth) {
|
|||
return true;
|
||||
}
|
||||
|
||||
return !!user;
|
||||
return hasPermission(user.role, PERMISSIONS.teamCreate);
|
||||
}
|
||||
|
||||
export async function canUpdateTeam({ user }: Auth, teamId: string) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue