From a47157cafad20da29de535347b3584a79c3a5874 Mon Sep 17 00:00:00 2001 From: Blayne Chard Date: Tue, 22 Feb 2022 17:43:02 +1300 Subject: [PATCH] fix(core): include .clear() in the tiny map --- packages/core/src/chunk.source.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/core/src/chunk.source.ts b/packages/core/src/chunk.source.ts index 78fd4183..4a4ea151 100644 --- a/packages/core/src/chunk.source.ts +++ b/packages/core/src/chunk.source.ts @@ -18,6 +18,7 @@ interface TinyMap { get(key: K): V | undefined; set(key: K, value: V): unknown; has(key: K): boolean; + clear(): unknown; } /** @@ -27,7 +28,7 @@ interface TinyMap { * * This will also handle joining of consecutive requests, even when it is semi consecutive */ -export abstract class ChunkSourceBase implements ChunkSource { +export class ChunkSourceBase implements ChunkSource { /** By default create a new cache for every chunk source */ static DefaultChunkCache = (): TinyMap => new Map();