(ctx context.Context, threshold database.DeleteOldAuditLogConnectionEventsParams)
| 2166 | } |
| 2167 | |
| 2168 | func (q *querier) DeleteOldAuditLogConnectionEvents(ctx context.Context, threshold database.DeleteOldAuditLogConnectionEventsParams) error { |
| 2169 | // `ResourceSystem` is deprecated, but it doesn't make sense to add |
| 2170 | // `policy.ActionDelete` to `ResourceAuditLog`, since this is the one and |
| 2171 | // only time we'll be deleting from the audit log. |
| 2172 | if err := q.authorizeContext(ctx, policy.ActionDelete, rbac.ResourceSystem); err != nil { |
| 2173 | return err |
| 2174 | } |
| 2175 | return q.db.DeleteOldAuditLogConnectionEvents(ctx, threshold) |
| 2176 | } |
| 2177 | |
| 2178 | func (q *querier) DeleteOldAuditLogs(ctx context.Context, arg database.DeleteOldAuditLogsParams) (int64, error) { |
| 2179 | if err := q.authorizeContext(ctx, policy.ActionDelete, rbac.ResourceSystem); err != nil { |
nothing calls this directly
no test coverage detected