From 3b5be4d358f9fd097864e4356d9c2b688b9676a0 Mon Sep 17 00:00:00 2001 From: "P. Reis" Date: Mon, 12 Aug 2024 17:10:39 -0300 Subject: [PATCH] fix: cast signal as unknown first and then cast as AbortSignal --- src/utils/SimpleLRU.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils/SimpleLRU.ts b/src/utils/SimpleLRU.ts index f1bf6512..0f2b5b37 100644 --- a/src/utils/SimpleLRU.ts +++ b/src/utils/SimpleLRU.ts @@ -17,7 +17,7 @@ export class SimpleLRU< constructor(fetchFn: FetchFn, opts: LRUCache.Options) { this.cache = new LRUCache({ - fetchMethod: (key, _staleValue, { signal }) => fetchFn(key, { signal: signal as AbortSignal }), + fetchMethod: (key, _staleValue, { signal }) => fetchFn(key, { signal: signal as unknown as AbortSignal }), ...opts, }); }