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

Function IsWorkloadIdentityEmail

backend/common/resource_name.go:559–561  ·  view source on GitHub ↗

IsWorkloadIdentityEmail checks if the email is a workload identity email.

(email string)

Source from the content-addressed store, hash-verified

557
558// IsWorkloadIdentityEmail checks if the email is a workload identity email.
559func IsWorkloadIdentityEmail(email string) bool {
560 return strings.HasSuffix(email, fmt.Sprintf("@%s", WorkloadIdentitySuffix)) || isProjectLevelEmail(email, WorkloadIdentitySuffix)
561}
562
563// isProjectLevelEmail checks if the email is a project-level email.
564func isProjectLevelEmail(email, suffix string) bool {

Callers 3

GetAccountByEmailMethod · 0.92
validateEndUserEmailFunction · 0.92

Calls 1

isProjectLevelEmailFunction · 0.85

Tested by

no test coverage detected