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

Method UpdateChatHeartbeats

coderd/database/dbauthz/dbauthz.go:6636–6645  ·  view source on GitHub ↗
(ctx context.Context, arg database.UpdateChatHeartbeatsParams)

Source from the content-addressed store, hash-verified

6634}
6635
6636func (q *querier) UpdateChatHeartbeats(ctx context.Context, arg database.UpdateChatHeartbeatsParams) ([]uuid.UUID, error) {
6637 // The batch heartbeat is a system-level operation filtered by
6638 // worker_id. Authorization is enforced by the AsChatd context
6639 // at the call site rather than per-row, because checking each
6640 // row individually would defeat the purpose of batching.
6641 if err := q.authorizeContext(ctx, policy.ActionUpdate, rbac.ResourceChat); err != nil {
6642 return nil, err
6643 }
6644 return q.db.UpdateChatHeartbeats(ctx, arg)
6645}
6646
6647func (q *querier) UpdateChatLabelsByID(ctx context.Context, arg database.UpdateChatLabelsByIDParams) (database.Chat, error) {
6648 chat, err := q.db.GetChatByID(ctx, arg.ID)

Callers

nothing calls this directly

Calls 2

authorizeContextMethod · 0.95
UpdateChatHeartbeatsMethod · 0.65

Tested by

no test coverage detected