MCPcopy Index your code
hub / github.com/coder/coder / blankFields

Function blankFields

coderd/userauth.go:1642–1651  ·  view source on GitHub ↗

blankFields returns the list of fields in the claims map that are an empty string.

(claims map[string]interface{})

Source from the content-addressed store, hash-verified

1640// blankFields returns the list of fields in the claims map that are
1641// an empty string.
1642func blankFields(claims map[string]interface{}) []string {
1643 fields := make([]string, 0)
1644 for field, value := range claims {
1645 if valueStr, ok := value.(string); ok && valueStr == "" {
1646 fields = append(fields, field)
1647 }
1648 }
1649 slices.Sort(fields)
1650 return fields
1651}
1652
1653// mergeClaims merges the claims from a and b and returns the merged set.
1654// claims from b take precedence over claims from a.

Callers 2

userOIDCMethod · 0.85
userInfoClaimsMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected