Refactor cache storage to use cacheCommandOutput for consistency

This commit is contained in:
Mario Campos
2026-06-19 17:49:45 -05:00
parent 895ffe7eb5
commit 649bababe7
2 changed files with 2 additions and 2 deletions

2
lib/entry-points.js generated
View File

@@ -149957,7 +149957,7 @@ function getCachedCommandOutput(key, cmd, validate) {
if (!isObject(entry) || !isString(entry.cmd) || cmd !== void 0 && entry.cmd !== cmd || validate !== void 0 && !validate(entry.output)) {
return void 0;
}
inMemoryCache.set(key, { cmd: entry.cmd, output: entry.output });
cacheCommandOutput(key, entry.cmd, entry.output);
return entry.output;
}

View File

@@ -125,7 +125,7 @@ export function getCachedCommandOutput<T>(
}
// Memoize so subsequent lookups in this process hit tier 1.
inMemoryCache.set(key, { cmd: entry.cmd, output: entry.output });
cacheCommandOutput(key, entry.cmd, entry.output);
return entry.output as T;
}