diff --git a/dist/cache-save/index.js b/dist/cache-save/index.js index 10c9ec5..d90d374 100644 --- a/dist/cache-save/index.js +++ b/dist/cache-save/index.js @@ -60457,12 +60457,12 @@ const getPackageManagerInfo = (packageManager) => __awaiter(void 0, void 0, void }); exports.getPackageManagerInfo = getPackageManagerInfo; const getCacheDirectoryPath = (packageManagerInfo) => __awaiter(void 0, void 0, void 0, function* () { - let pathList = yield Promise.all(packageManagerInfo.cacheFolderCommandList.map(command => exports.getCommandOutput(command))); - const emptyPaths = pathList.filter(item => !item); - if (emptyPaths.length) { + const pathList = yield Promise.all(packageManagerInfo.cacheFolderCommandList.map(command => exports.getCommandOutput(command))); + const cachePaths = pathList.filter(item => item); + if (!cachePaths.length) { throw new Error(`Could not get cache folder paths.`); } - return pathList; + return cachePaths; }); exports.getCacheDirectoryPath = getCacheDirectoryPath; function isGhes() { diff --git a/dist/setup/index.js b/dist/setup/index.js index b3b74ee..cbc2a3c 100644 --- a/dist/setup/index.js +++ b/dist/setup/index.js @@ -63130,12 +63130,12 @@ const getPackageManagerInfo = (packageManager) => __awaiter(void 0, void 0, void }); exports.getPackageManagerInfo = getPackageManagerInfo; const getCacheDirectoryPath = (packageManagerInfo) => __awaiter(void 0, void 0, void 0, function* () { - let pathList = yield Promise.all(packageManagerInfo.cacheFolderCommandList.map(command => exports.getCommandOutput(command))); - const emptyPaths = pathList.filter(item => !item); - if (emptyPaths.length) { + const pathList = yield Promise.all(packageManagerInfo.cacheFolderCommandList.map(command => exports.getCommandOutput(command))); + const cachePaths = pathList.filter(item => item); + if (!cachePaths.length) { throw new Error(`Could not get cache folder paths.`); } - return pathList; + return cachePaths; }); exports.getCacheDirectoryPath = getCacheDirectoryPath; function isGhes() {