From ffb3400b2659765a8b35d0f2d07e297825aab438 Mon Sep 17 00:00:00 2001 From: La'Kaleigh Harris <35268101+Xlient@users.noreply.github.com> Date: Mon, 22 Nov 2021 17:56:37 +0000 Subject: [PATCH] minor refactorings --- dist/index.js | 2 +- src/setup-dotnet.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dist/index.js b/dist/index.js index 8eb9778..74c9c1a 100644 --- a/dist/index.js +++ b/dist/index.js @@ -8680,7 +8680,7 @@ function run() { core.debug('No version found, trying to find version from global.json'); const globalJsonPath = path.join(process.cwd(), 'global.json'); if (fs.existsSync(globalJsonPath)) { - versions[0] = getVersionFromGlobalJson(globalJsonPath); + versions.push(getVersionFromGlobalJson(globalJsonPath)); } } if (versions.length) { diff --git a/src/setup-dotnet.ts b/src/setup-dotnet.ts index 527f54d..f82bb14 100644 --- a/src/setup-dotnet.ts +++ b/src/setup-dotnet.ts @@ -19,7 +19,7 @@ export async function run() { core.debug('No version found, trying to find version from global.json'); const globalJsonPath = path.join(process.cwd(), 'global.json'); if (fs.existsSync(globalJsonPath)) { - versions[0] = getVersionFromGlobalJson(globalJsonPath); + versions.push(getVersionFromGlobalJson(globalJsonPath)); } }