MCPcopy Create free account
hub / github.com/GoMudEngine/GoMud / Exists

Function Exists

internal/users/users.go:735–747  ·  view source on GitHub ↗
(name string)

Source from the content-addressed store, hash-verified

733}
734
735func Exists(name string) bool {
736
737 for _, u := range GetAllActiveUsers() {
738 if strings.ToLower(u.Username) == strings.ToLower(name) {
739 return true
740 }
741 }
742
743 idx := GetUserIndex()
744 _, found := idx.FindByUsername(name)
745
746 return found
747}
748
749func FindUserId(username string) int {
750 idx := GetUserIndex()

Callers 3

FinalizeLoginOrCreateFunction · 0.92
apiV1CreateUserFunction · 0.92
ValidateNameFunction · 0.70

Calls 3

GetAllActiveUsersFunction · 0.85
GetUserIndexFunction · 0.85
FindByUsernameMethod · 0.80

Tested by

no test coverage detected