diff --git a/src/extractor/ExtractorRegistry.ts b/src/extractor/ExtractorRegistry.ts index 37f9db7..b48e4ad 100644 --- a/src/extractor/ExtractorRegistry.ts +++ b/src/extractor/ExtractorRegistry.ts @@ -39,7 +39,7 @@ export class ExtractorRegistry { ? `${extractor.id}_${normalizedUrl}_${ctx.config.mediaFlowProxyUrl}` : `${extractor.id}_${normalizedUrl}`; - const storedDataRaw = await this.urlResultCache.get(cacheKey, { raw: true }); + const storedDataRaw = await this.urlResultCache.getRaw(cacheKey); const expires = storedDataRaw?.expires; if (storedDataRaw && expires) { // Ignore the cache randomly after at least 2/3 of the TTL passed to start refreshing results slowly diff --git a/src/utils/Fetcher.ts b/src/utils/Fetcher.ts index bd5694b..b3bde20 100644 --- a/src/utils/Fetcher.ts +++ b/src/utils/Fetcher.ts @@ -262,7 +262,7 @@ export class Fetcher { protected async fetchWithTimeout(ctx: Context, url: URL, init?: CustomRequestInit, tryCount = 0): Promise { this.logger.info(`Fetch ${init?.method ?? 'GET'} ${url}`, ctx); - const isRateLimitedRaw = await this.rateLimitedCache.get(url.host, { raw: true }); + const isRateLimitedRaw = await this.rateLimitedCache.getRaw(url.host); /* istanbul ignore if */ if (isRateLimitedRaw && isRateLimitedRaw.value && isRateLimitedRaw.expires) { const ttl = isRateLimitedRaw.expires - Date.now();