MCPcopy Index your code
hub / github.com/tinode/chat / userGetState

Function userGetState

server/user.go:688–697  ·  view source on GitHub ↗

Read user's state from DB.

(uid types.Uid)

Source from the content-addressed store, hash-verified

686
687// Read user's state from DB.
688func userGetState(uid types.Uid) (types.ObjState, error) {
689 user, err := store.Users.Get(uid)
690 if err != nil {
691 return types.StateUndefined, err
692 }
693 if user == nil {
694 return types.StateUndefined, types.ErrUserNotFound
695 }
696 return user.State, nil
697}
698
699// Subscribe or unsubscribe a single user's device to/from all FCM topics (channels).
700func userChannelsSubUnsub(uid types.Uid, deviceID string, sub bool) {

Callers 1

loginMethod · 0.85

Calls 1

GetMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…