From 7d1640d6a158670a99b9077c2e76b3f6629e4c2e Mon Sep 17 00:00:00 2001 From: Josh Gross Date: Fri, 13 Dec 2019 15:32:00 -0500 Subject: [PATCH] Fix cacheEntry type --- src/restore.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/restore.ts b/src/restore.ts index 599dbd7..aa8761c 100644 --- a/src/restore.ts +++ b/src/restore.ts @@ -60,7 +60,7 @@ async function run(): Promise { try { const cacheEntry = await cacheHttpClient.getCacheEntry(keys); - if (!cacheEntry) { + if (!cacheEntry || !cacheEntry?.archiveLocation) { core.info( `Cache not found for input keys: ${keys.join(", ")}.` ); @@ -77,7 +77,7 @@ async function run(): Promise { utils.setCacheState(cacheEntry); // Download the cache from the cache entry - await cacheHttpClient.downloadCache(cacheEntry, archivePath); + await cacheHttpClient.downloadCache(cacheEntry?.archiveLocation, archivePath); const archiveFileSize = utils.getArchiveFileSize(archivePath); core.info(