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

Method GetUserSecretByUserIDAndName

coderd/database/dbauthz/dbauthz.go:4749–4756  ·  view source on GitHub ↗
(ctx context.Context, arg database.GetUserSecretByUserIDAndNameParams)

Source from the content-addressed store, hash-verified

4747}
4748
4749func (q *querier) GetUserSecretByUserIDAndName(ctx context.Context, arg database.GetUserSecretByUserIDAndNameParams) (database.UserSecret, error) {
4750 obj := rbac.ResourceUserSecret.WithOwner(arg.UserID.String())
4751 if err := q.authorizeContext(ctx, policy.ActionRead, obj); err != nil {
4752 return database.UserSecret{}, err
4753 }
4754
4755 return q.db.GetUserSecretByUserIDAndName(ctx, arg)
4756}
4757
4758func (q *querier) GetUserSecretsTelemetrySummary(ctx context.Context) (database.GetUserSecretsTelemetrySummaryRow, error) {
4759 // Telemetry queries are called from system contexts only. The

Callers

nothing calls this directly

Calls 4

authorizeContextMethod · 0.95
WithOwnerMethod · 0.80
StringMethod · 0.45

Tested by

no test coverage detected