From 2098132e3cd153c43b449b26037f36046e1de411 Mon Sep 17 00:00:00 2001 From: Zachary Taylor Date: Wed, 1 Jan 2025 23:55:11 +0000 Subject: [PATCH] Remove logic for azureedge.net fallback in preparation for install script changes (v3) --- dist/setup/index.js | 1 - src/installer.ts | 16 +++------------- 2 files changed, 3 insertions(+), 14 deletions(-) diff --git a/dist/setup/index.js b/dist/setup/index.js index d719bfd..2709645 100644 --- a/dist/setup/index.js +++ b/dist/setup/index.js @@ -71286,7 +71286,6 @@ class DotnetVersionResolver { } exports.DotnetVersionResolver = DotnetVersionResolver; DotnetVersionResolver.DotNetCoreIndexUrl = 'https://builds.dotnet.microsoft.com/dotnet/release-metadata/releases-index.json'; -DotnetVersionResolver.DotnetCoreIndexFallbackUrl = 'https://dotnetcli.azureedge.net/dotnet/release-metadata/releases-index.json'; class DotnetCoreInstaller { constructor(version, quality) { this.version = version; diff --git a/src/installer.ts b/src/installer.ts index 027f095..488379c 100644 --- a/src/installer.ts +++ b/src/installer.ts @@ -102,16 +102,9 @@ export class DotnetVersionResolver { maxRetries: 3 }); - let response; - try { - response = await httpClient.getJson( - DotnetVersionResolver.DotNetCoreIndexUrl - ); - } catch (error) { - response = await httpClient.getJson( - DotnetVersionResolver.DotnetCoreIndexFallbackUrl - ); - } + const response = await httpClient.getJson( + DotnetVersionResolver.DotNetCoreIndexUrl + ); const result = response.result || {}; const releasesInfo: any[] = result['releases-index']; @@ -132,9 +125,6 @@ export class DotnetVersionResolver { static DotNetCoreIndexUrl = 'https://builds.dotnet.microsoft.com/dotnet/release-metadata/releases-index.json'; - - static DotnetCoreIndexFallbackUrl = - 'https://dotnetcli.azureedge.net/dotnet/release-metadata/releases-index.json'; } export class DotnetCoreInstaller {