From 8f5dc4316ccec75c50116ec8f255dabf173b7b75 Mon Sep 17 00:00:00 2001 From: Ryan LaForge Date: Fri, 23 Sep 2022 13:01:47 -0600 Subject: [PATCH] [fix]: if the path does not exist log an error rather than crashing --- src/cache-save.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cache-save.ts b/src/cache-save.ts index 121d9a2..056c464 100644 --- a/src/cache-save.ts +++ b/src/cache-save.ts @@ -35,7 +35,8 @@ export const cacheBinary = async () => { const primaryKey = core.getState(State.CachePrimaryKey); const path = core.getState(State.BinaryPath); if (!fs.existsSync(path)) { - throw new Error(`Cache folder path doesn't exist on disk: ${path}`); + core.warning(`Cache folder path doesn't exist on disk, skipping cache: ${path}`); + return; } core.debug(