mirror of
https://github.com/dbeaver/cloudbeaver.git
synced 2026-09-24 16:04:36 +08:00
CB-2550 check that team is not granted yet (#1375)
This commit is contained in:
+3
-1
@@ -295,7 +295,9 @@ export class UserFormController implements IInitializableController, IDestructib
|
||||
await this.usersResource.grantTeam(this.user.userId, teamId, true);
|
||||
}
|
||||
} else {
|
||||
await this.usersResource.revokeTeam(this.user.userId, teamId, true);
|
||||
if (this.user.grantedTeams.includes(teamId)) {
|
||||
await this.usersResource.revokeTeam(this.user.userId, teamId, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user