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

Function validateServiceAccountEmail

backend/api/v1/account_email_validation.go:9–17  ·  view source on GitHub ↗
(email string)

Source from the content-addressed store, hash-verified

7)
8
9func validateServiceAccountEmail(email string) error {
10 if err := common.ValidateEmail(email); err != nil {
11 return err
12 }
13 if !common.IsServiceAccountEmail(email) {
14 return errors.Errorf("email must end with %s", common.ServiceAccountSuffix)
15 }
16 return nil
17}
18
19func validateWorkloadIdentityEmail(email string) error {
20 if err := common.ValidateEmail(email); err != nil {

Callers 6

CreateServiceAccountMethod · 0.85
GetServiceAccountMethod · 0.85
UpdateServiceAccountMethod · 0.85
DeleteServiceAccountMethod · 0.85

Calls 3

ValidateEmailFunction · 0.92
IsServiceAccountEmailFunction · 0.92
ErrorfMethod · 0.80

Tested by 1