MCPcopy Create free account
hub / github.com/OpenCSGs/csghub-server / FindByID

Method FindByID

builder/store/database/user.go:97–101  ·  view source on GitHub ↗
(ctx context.Context, id int)

Source from the content-addressed store, hash-verified

95}
96
97func (s *UserStore) FindByID(ctx context.Context, id int) (user User, err error) {
98 user.ID = int64(id)
99 err = s.db.Operator.Core.NewSelect().Model(&user).WherePK().Scan(ctx)
100 return
101}
102
103func (s *UserStore) Update(ctx context.Context, user *User) (err error) {
104 err = assertAffectedOneRow(s.db.Operator.Core.NewUpdate().

Callers 15

CreateMethod · 0.45
DeployMethod · 0.45
ListLocksMethod · 0.45
UnLockMethod · 0.45
UpdateMethod · 0.45
DeleteMethod · 0.45
UpdateMethod · 0.45
DeleteMethod · 0.45
GetDiscussionMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected