───────────────────────── TokenRevocationStorage ─────────────────────────
(ctx context.Context, requestID string)
| 463 | // ───────────────────────── TokenRevocationStorage ───────────────────────── |
| 464 | |
| 465 | func (s *Storage) RevokeRefreshToken(ctx context.Context, requestID string) error { |
| 466 | _, err := s.db(ctx).Exec(ctx, ` |
| 467 | UPDATE oauth_refresh_tokens |
| 468 | SET revoked_at = NOW(), active = FALSE |
| 469 | WHERE request_id = $1 AND revoked_at IS NULL |
| 470 | `, requestID) |
| 471 | return err |
| 472 | } |
| 473 | |
| 474 | func (s *Storage) RevokeAccessToken(ctx context.Context, requestID string) error { |
| 475 | _, err := s.db(ctx).Exec(ctx, ` |