MCPcopy Index your code
hub / github.com/coder/coder / GetUserShellToolDisplayMode

Method GetUserShellToolDisplayMode

coderd/database/dbauthz/dbauthz.go:4769–4778  ·  view source on GitHub ↗
(ctx context.Context, userID uuid.UUID)

Source from the content-addressed store, hash-verified

4767}
4768
4769func (q *querier) GetUserShellToolDisplayMode(ctx context.Context, userID uuid.UUID) (string, error) {
4770 user, err := q.db.GetUserByID(ctx, userID)
4771 if err != nil {
4772 return "", err
4773 }
4774 if err := q.authorizeContext(ctx, policy.ActionReadPersonal, user); err != nil {
4775 return "", err
4776 }
4777 return q.db.GetUserShellToolDisplayMode(ctx, userID)
4778}
4779
4780func (q *querier) GetUserSkillByUserIDAndName(ctx context.Context, arg database.GetUserSkillByUserIDAndNameParams) (database.UserSkill, error) {
4781 obj := rbac.ResourceUserSkill.WithOwner(arg.UserID.String())

Callers

nothing calls this directly

Calls 3

authorizeContextMethod · 0.95
GetUserByIDMethod · 0.65

Tested by

no test coverage detected