(ctx context.Context, userID uuid.UUID)
| 3809 | } |
| 3810 | |
| 3811 | func (q *querier) GetOAuth2ProviderAppsByUserID(ctx context.Context, userID uuid.UUID) ([]database.GetOAuth2ProviderAppsByUserIDRow, error) { |
| 3812 | // This authz check is to make sure the caller can read all their own tokens. |
| 3813 | if err := q.authorizeContext(ctx, policy.ActionRead, |
| 3814 | rbac.ResourceOauth2AppCodeToken.WithOwner(userID.String())); err != nil { |
| 3815 | return []database.GetOAuth2ProviderAppsByUserIDRow{}, err |
| 3816 | } |
| 3817 | return q.db.GetOAuth2ProviderAppsByUserID(ctx, userID) |
| 3818 | } |
| 3819 | |
| 3820 | func (q *querier) GetOrganizationByID(ctx context.Context, id uuid.UUID) (database.Organization, error) { |
| 3821 | return fetch(q.log, q.auth, q.db.GetOrganizationByID)(ctx, id) |
nothing calls this directly
no test coverage detected