(ctx context.Context, workspaceID uuid.UUID)
| 6265 | } |
| 6266 | |
| 6267 | func (q *querier) ListWorkspaceAgentPortShares(ctx context.Context, workspaceID uuid.UUID) ([]database.WorkspaceAgentPortShare, error) { |
| 6268 | workspace, err := q.db.GetWorkspaceByID(ctx, workspaceID) |
| 6269 | if err != nil { |
| 6270 | return nil, err |
| 6271 | } |
| 6272 | |
| 6273 | // listing port shares is more akin to reading the workspace. |
| 6274 | if err := q.authorizeContext(ctx, policy.ActionRead, workspace); err != nil { |
| 6275 | return nil, err |
| 6276 | } |
| 6277 | |
| 6278 | return q.db.ListWorkspaceAgentPortShares(ctx, workspaceID) |
| 6279 | } |
| 6280 | |
| 6281 | func (q *querier) MarkAllInboxNotificationsAsRead(ctx context.Context, arg database.MarkAllInboxNotificationsAsReadParams) error { |
| 6282 | resource := rbac.ResourceInboxNotification.WithOwner(arg.UserID.String()) |
nothing calls this directly
no test coverage detected