MCPcopy Create free account
hub / github.com/bytebase/bytebase / GetUserGroups

Method GetUserGroups

backend/component/iam/manager.go:103–105  ·  view source on GitHub ↗
(ctx context.Context, workspaceID string, email string)

Source from the content-addressed store, hash-verified

101}
102
103func (m *Manager) GetUserGroups(ctx context.Context, workspaceID string, email string) ([]string, error) {
104 return m.store.GetUserGroupsSnapshot(ctx, workspaceID, common.FormatUserEmail(email))
105}
106
107func check(user *store.UserMessage, p permission.Permission, policy *storepb.IamPolicy, getPermissions func(role string) map[permission.Permission]bool, getGroupMembers func(groupName string) map[string]bool, skipAllUsers bool) bool {
108 userName := formatUserNameByType(user)

Callers 1

convertToUserFunction · 0.80

Calls 2

FormatUserEmailFunction · 0.92
GetUserGroupsSnapshotMethod · 0.80

Tested by

no test coverage detected