MCPcopy Create free account
hub / github.com/ShipSecAI/studio / hasAdminRole

Function hasAdminRole

frontend/src/utils/auth.ts:20–22  ·  view source on GitHub ↗
(roles: string[])

Source from the content-addressed store, hash-verified

18 * Check if a user has admin role
19 */
20export function hasAdminRole(roles: string[]): boolean {
21 return roles.some((role) => normalizeRole(role) === 'ADMIN');
22}

Callers 6

AppLayoutFunction · 0.90
ApiKeysManagerFunction · 0.90
AnalyticsSettingsPageFunction · 0.90
SecretsManagerFunction · 0.90
WorkflowListFunction · 0.90
WorkflowBuilderContentFunction · 0.90

Calls 1

normalizeRoleFunction · 0.85

Tested by

no test coverage detected