()
| 370 | } |
| 371 | |
| 372 | private async backfillIfNeeded(): Promise<void> { |
| 373 | if (!this.needsBackfill) { |
| 374 | return |
| 375 | } |
| 376 | try { |
| 377 | await this.backfillMessages() |
| 378 | this.needsBackfill = false |
| 379 | } catch (error) { |
| 380 | logger.debug('[API] Backfill failed', error) |
| 381 | this.needsBackfill = true |
| 382 | } |
| 383 | } |
| 384 | |
| 385 | private async backfillMessages(): Promise<void> { |
| 386 | if (this.backfillInFlight) { |
no test coverage detected