Skip to content

Commit 7d02032

Browse files
committed
Initialize cache variable closer to usage
1 parent ee36e8b commit 7d02032

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ export async function run() {
2020
const version = resolveVersionInput();
2121

2222
let arch = core.getInput('architecture');
23-
const cache = core.getInput('cache');
2423

2524
// if architecture supplied but node-version is not
2625
// if we don't throw a warning, the already installed x64 node will be used which is not probably what user meant.
@@ -60,6 +59,7 @@ export async function run() {
6059
auth.configAuthentication(registryUrl, alwaysAuth);
6160
}
6261

62+
const cache = core.getInput('cache');
6363
if (cache && isCacheFeatureAvailable()) {
6464
core.saveState(State.CachePackageManager, cache);
6565
const cacheDependencyPath = core.getInput('cache-dependency-path');

0 commit comments

Comments
 (0)