(sessionId: string)
| 230 | } |
| 231 | |
| 232 | function cancel(sessionId: string): void { |
| 233 | // Bump generation to invalidate any in-flight async doRefresh. |
| 234 | nextGeneration(sessionId) |
| 235 | const timer = timers.get(sessionId) |
| 236 | if (timer) { |
| 237 | clearTimeout(timer) |
| 238 | timers.delete(sessionId) |
| 239 | } |
| 240 | failureCounts.delete(sessionId) |
| 241 | } |
| 242 | |
| 243 | function cancelAll(): void { |
| 244 | // Bump all generations so in-flight doRefresh calls are invalidated. |
no test coverage detected