mirror of
https://github.com/actions/setup-java.git
synced 2025-11-06 17:30:53 +00:00
Fix fetchReleasesFromUrl to remove unnecessary headers for backup URL
This commit is contained in:
parent
65d2f80cdf
commit
fcb4621416
2 changed files with 2 additions and 3 deletions
2
dist/setup/index.js
vendored
2
dist/setup/index.js
vendored
|
|
@ -131522,7 +131522,7 @@ class SapMachineDistribution extends base_installer_1.JavaBase {
|
||||||
const arch = this.distributionArchitecture();
|
const arch = this.distributionArchitecture();
|
||||||
let fetchedReleasesJson = yield this.fetchReleasesFromUrl('https://sapmachine.io/assets/data/sapmachine-releases-all.json');
|
let fetchedReleasesJson = yield this.fetchReleasesFromUrl('https://sapmachine.io/assets/data/sapmachine-releases-all.json');
|
||||||
if (!fetchedReleasesJson) {
|
if (!fetchedReleasesJson) {
|
||||||
fetchedReleasesJson = yield this.fetchReleasesFromUrl('https://sap.github.io/SapMachine/assets/data/sapmachine-releases-all.json', (0, util_1.getGitHubHttpHeaders)());
|
fetchedReleasesJson = yield this.fetchReleasesFromUrl('https://sap.github.io/SapMachine/assets/data/sapmachine-releases-all.json');
|
||||||
}
|
}
|
||||||
if (!fetchedReleasesJson) {
|
if (!fetchedReleasesJson) {
|
||||||
throw new Error(`Couldn't fetch SapMachine versions information from both primary and backup urls`);
|
throw new Error(`Couldn't fetch SapMachine versions information from both primary and backup urls`);
|
||||||
|
|
|
||||||
|
|
@ -69,8 +69,7 @@ export class SapMachineDistribution extends JavaBase {
|
||||||
|
|
||||||
if (!fetchedReleasesJson) {
|
if (!fetchedReleasesJson) {
|
||||||
fetchedReleasesJson = await this.fetchReleasesFromUrl(
|
fetchedReleasesJson = await this.fetchReleasesFromUrl(
|
||||||
'https://sap.github.io/SapMachine/assets/data/sapmachine-releases-all.json',
|
'https://backup.sapmachine.io/assets/data/sapmachine-releases-all.json'
|
||||||
getGitHubHttpHeaders()
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue