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

Function LoadUserById

internal/users/users.go:430–439  ·  view source on GitHub ↗
(userId int)

Source from the content-addressed store, hash-verified

428}
429
430func LoadUserById(userId int) (*UserRecord, error) {
431
432 idx := GetUserIndex()
433 username, found := idx.FindByUserId(userId)
434 if !found {
435 return nil, errors.New("user doesn't exist")
436 }
437
438 return LoadUser(username)
439}
440
441func LoadUser(username string, skipValidation ...bool) (*UserRecord, error) {
442

Callers 2

loadUserRecordFunction · 0.92
DeleteUserFunction · 0.85

Calls 4

GetUserIndexFunction · 0.85
LoadUserFunction · 0.85
FindByUserIdMethod · 0.80
NewMethod · 0.80

Tested by

no test coverage detected