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

Method UpdateWorkspaceBuildCostByID

coderd/database/dbauthz/dbauthz.go:7861–7866  ·  view source on GitHub ↗

UpdateWorkspaceBuildCostByID is used by the provisioning system to update the cost of a workspace build.

(ctx context.Context, arg database.UpdateWorkspaceBuildCostByIDParams)

Source from the content-addressed store, hash-verified

7859
7860// UpdateWorkspaceBuildCostByID is used by the provisioning system to update the cost of a workspace build.
7861func (q *querier) UpdateWorkspaceBuildCostByID(ctx context.Context, arg database.UpdateWorkspaceBuildCostByIDParams) error {
7862 if err := q.authorizeContext(ctx, policy.ActionUpdate, rbac.ResourceSystem); err != nil {
7863 return err
7864 }
7865 return q.db.UpdateWorkspaceBuildCostByID(ctx, arg)
7866}
7867
7868func (q *querier) UpdateWorkspaceBuildDeadlineByID(ctx context.Context, arg database.UpdateWorkspaceBuildDeadlineByIDParams) error {
7869 build, err := q.db.GetWorkspaceBuildByID(ctx, arg.ID)

Callers

nothing calls this directly

Calls 2

authorizeContextMethod · 0.95

Tested by

no test coverage detected