diff --git a/dist/setup/index.js b/dist/setup/index.js index 8cce9d25..cf9f4e0d 100644 --- a/dist/setup/index.js +++ b/dist/setup/index.js @@ -73293,7 +73293,7 @@ class BaseDistribution { core.info(`Found in cache @ ${toolPath}`); } else { - nodeVersions !== null && nodeVersions !== void 0 ? nodeVersions : (nodeVersions = yield this.getNodejsVersions()); + nodeVersions = nodeVersions !== null && nodeVersions !== void 0 ? nodeVersions : (yield this.getNodejsVersions()); const versions = this.filterVersions(nodeVersions); const evaluatedVersion = this.evaluateVersions(versions); if (!evaluatedVersion) { diff --git a/src/distibutions/base-distribution.ts b/src/distibutions/base-distribution.ts index c12ca43b..e6827ad8 100644 --- a/src/distibutions/base-distribution.ts +++ b/src/distibutions/base-distribution.ts @@ -42,7 +42,7 @@ export default abstract class BaseDistribution { if (toolPath) { core.info(`Found in cache @ ${toolPath}`); } else { - nodeVersions ??= await this.getNodejsVersions(); + nodeVersions = nodeVersions ?? (await this.getNodejsVersions()); const versions = this.filterVersions(nodeVersions); const evaluatedVersion = this.evaluateVersions(versions); if (!evaluatedVersion) {