From 800fa459153f2488ca726af656eac64a1fa42d40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alejandro=20Herna=CC=81ndez?= Date: Sun, 9 Jan 2022 11:02:42 +0100 Subject: [PATCH] Workspace should always be restored MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Alejandro Hernández --- src/main.ts | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/main.ts b/src/main.ts index 87e4a1c8..0e1aa2ca 100644 --- a/src/main.ts +++ b/src/main.ts @@ -37,9 +37,7 @@ async function run(): Promise { const cacheTtl = core.getInput('cache-ttl') - if (cacheTtl !== '0s') { - await workspace.restoreWorkspaceCache(workspaceDir) - } + await workspace.restoreWorkspaceCache(workspaceDir) const timeout = core.getInput('timeout') @@ -86,9 +84,7 @@ async function run(): Promise { githubAppArgs, ]) - if (cacheTtl !== '0') { - await workspace.saveWorkspaceCache(workspaceDir) - } + await workspace.saveWorkspaceCache(workspaceDir) } catch (error: unknown) { core.setFailed(` ✕ ${(error as Error).message}`) }