From 4ec328066cdda979a701ad6e7c7d8a0b4153c8dc Mon Sep 17 00:00:00 2001 From: Developing-Gamer Date: Wed, 27 May 2026 13:35:41 -0700 Subject: [PATCH] Refine team API keys and member invitation sections. Co-authored-by: Cursor --- .../teams/team-api-keys-section.tsx | 2 +- .../teams/team-member-invitation-section.tsx | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/apps/dashboard/src/components/dashboard-account-settings/teams/team-api-keys-section.tsx b/apps/dashboard/src/components/dashboard-account-settings/teams/team-api-keys-section.tsx index 79ce9fdd4..452a77cb7 100644 --- a/apps/dashboard/src/components/dashboard-account-settings/teams/team-api-keys-section.tsx +++ b/apps/dashboard/src/components/dashboard-account-settings/teams/team-api-keys-section.tsx @@ -13,13 +13,13 @@ export function TeamApiKeysSection(props: { team: Team }) { const team = user.useTeam(props.team.id); const stackApp = useStackApp(); const project = stackApp.useProject(); + const manageApiKeysPermission = user.usePermission(props.team, '$manage_api_keys'); if (!team) { throw new HexclaveAssertionError("Team not found"); } const teamApiKeysEnabled = project.config.allowTeamApiKeys; - const manageApiKeysPermission = user.usePermission(props.team, '$manage_api_keys'); if (!manageApiKeysPermission || !teamApiKeysEnabled) { return null; } diff --git a/apps/dashboard/src/components/dashboard-account-settings/teams/team-member-invitation-section.tsx b/apps/dashboard/src/components/dashboard-account-settings/teams/team-member-invitation-section.tsx index 218c0c728..6b7f57d88 100644 --- a/apps/dashboard/src/components/dashboard-account-settings/teams/team-member-invitation-section.tsx +++ b/apps/dashboard/src/components/dashboard-account-settings/teams/team-member-invitation-section.tsx @@ -75,7 +75,7 @@ function MemberInvitationsSectionInvitationsList(props: { team: Team }) { {removeMemberPermission && (