@@ -743,12 +743,10 @@ class DebugProxyCaptureStoreImpl {
|
743 | 743 | ) |
744 | 744 | .get(...sessionIds) as { count: number } |
745 | 745 | ).count ?? 0; |
746 | | -this.db |
747 | | -.prepare(`DELETE FROM capture_events WHERE session_id IN (${placeholders})`) |
748 | | -.run(...sessionIds); |
749 | | -this.db |
750 | | -.prepare(`DELETE FROM capture_sessions WHERE id IN (${placeholders})`) |
751 | | -.run(...sessionIds); |
| 746 | +this.db.prepare(`DELETE FROM capture_events WHERE session_id IN (${placeholders})`).run( |
| 747 | + ...sessionIds, |
| 748 | +); |
| 749 | +this.db.prepare(`DELETE FROM capture_sessions WHERE id IN (${placeholders})`).run(...sessionIds); |
752 | 750 | const candidateBlobIds = blobRows |
753 | 751 | .map((row) => row.blobId?.trim()) |
754 | 752 | .filter((blobId): blobId is string => Boolean(blobId)); |
@@ -785,7 +783,10 @@ class DebugProxyCaptureStoreImpl {
|
785 | 783 | } |
786 | 784 | |
787 | 785 | export type DebugProxyCaptureStore = Omit<DebugProxyCaptureStoreImpl, "persistPayload"> & { |
788 | | -persistPayload(data: Buffer, contentType?: string): CaptureBlobRecord | SharedCaptureBlobRecord; |
| 786 | +persistPayload( |
| 787 | +data: Buffer, |
| 788 | +contentType?: string, |
| 789 | +): CaptureBlobRecord | SharedCaptureBlobRecord; |
789 | 790 | }; |
790 | 791 | |
791 | 792 | export type LegacyDebugProxyCaptureStore = Omit<DebugProxyCaptureStoreImpl, "persistPayload"> & { |
@@ -859,10 +860,7 @@ export function closeDebugProxyCaptureStore(): void {
|
859 | 860 | |
860 | 861 | // Lease API keeps one cached capture-store wrapper alive across related |
861 | 862 | // operations, then releases it without closing the shared state database. |
862 | | -export function acquireDebugProxyCaptureStore( |
863 | | -dbPath: string, |
864 | | -blobDir: string, |
865 | | -): { |
| 863 | +export function acquireDebugProxyCaptureStore(dbPath: string, blobDir: string): { |
866 | 864 | store: LegacyDebugProxyCaptureStore; |
867 | 865 | release: () => void; |
868 | 866 | }; |
@@ -907,7 +905,10 @@ export function acquireDebugProxyCaptureStore(
|
907 | 905 | |
908 | 906 | export function persistEventPayload( |
909 | 907 | store: { |
910 | | -persistPayload(data: Buffer, contentType?: string): CaptureBlobRecord | SharedCaptureBlobRecord; |
| 908 | +persistPayload( |
| 909 | +data: Buffer, |
| 910 | +contentType?: string, |
| 911 | +): CaptureBlobRecord | SharedCaptureBlobRecord; |
911 | 912 | }, |
912 | 913 | params: { data?: Buffer | string | null; contentType?: string; previewLimit?: number }, |
913 | 914 | ): { dataText?: string; dataBlobId?: string; dataSha256?: string } { |
|