MCPcopy Create free account
hub / github.com/gogs/gogs / IsErrEmailAlreadyUsed

Function IsErrEmailAlreadyUsed

internal/database/users.go:272–274  ·  view source on GitHub ↗

IsErrEmailAlreadyUsed returns true if the underlying error has the type ErrEmailAlreadyUsed.

(err error)

Source from the content-addressed store, hash-verified

270// IsErrEmailAlreadyUsed returns true if the underlying error has the type
271// ErrEmailAlreadyUsed.
272func IsErrEmailAlreadyUsed(err error) bool {
273 return errors.As(err, &ErrEmailAlreadyUsed{})
274}
275
276func (err ErrEmailAlreadyUsed) Email() string {
277 email, ok := err.args["email"].(string)

Callers 7

SignUpPostFunction · 0.92
SettingsEmailPostFunction · 0.92
AddEmailFunction · 0.92
CreateUserFunction · 0.92
EditUserFunction · 0.92
NewUserPostFunction · 0.92
EditUserPostFunction · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected