mirror of
https://github.com/actions/setup-java.git
synced 2026-04-07 06:48:53 +00:00
Fix redundant ternary expression in getAvailableVersions
Removed unused archParam variable that always returned arch regardless of condition. The new metadata API doesn't use hw_bitness parameter, so arch is used directly. Agent-Logs-Url: https://github.com/nbauma109/setup-java/sessions/defb7621-9c39-4bcc-a345-2eb4f3447e39 Co-authored-by: nbauma109 <9403560+nbauma109@users.noreply.github.com>
This commit is contained in:
parent
a06c8ec39e
commit
3f583bc86a
3
dist/setup/index.js
vendored
3
dist/setup/index.js
vendored
@ -114787,12 +114787,11 @@ class ZuluDistribution extends base_installer_1.JavaBase {
|
|||||||
console.time('Retrieving available versions for Zulu took'); // eslint-disable-line no-console
|
console.time('Retrieving available versions for Zulu took'); // eslint-disable-line no-console
|
||||||
}
|
}
|
||||||
// Map old API parameters to new metadata API parameters
|
// Map old API parameters to new metadata API parameters
|
||||||
const archParam = hw_bitness === '64' ? arch : arch;
|
|
||||||
const osParam = this.getOsParam(platform);
|
const osParam = this.getOsParam(platform);
|
||||||
const archiveType = this.getArchiveType(extension);
|
const archiveType = this.getArchiveType(extension);
|
||||||
const requestArguments = [
|
const requestArguments = [
|
||||||
`os=${osParam}`,
|
`os=${osParam}`,
|
||||||
`arch=${archParam}`,
|
`arch=${arch}`,
|
||||||
`archive_type=${archiveType}`,
|
`archive_type=${archiveType}`,
|
||||||
`java_package_type=${bundleType}`,
|
`java_package_type=${bundleType}`,
|
||||||
`javafx_bundled=${javafx}`,
|
`javafx_bundled=${javafx}`,
|
||||||
|
|||||||
@ -113,13 +113,12 @@ export class ZuluDistribution extends JavaBase {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Map old API parameters to new metadata API parameters
|
// Map old API parameters to new metadata API parameters
|
||||||
const archParam = hw_bitness === '64' ? arch : arch;
|
|
||||||
const osParam = this.getOsParam(platform);
|
const osParam = this.getOsParam(platform);
|
||||||
const archiveType = this.getArchiveType(extension);
|
const archiveType = this.getArchiveType(extension);
|
||||||
|
|
||||||
const requestArguments = [
|
const requestArguments = [
|
||||||
`os=${osParam}`,
|
`os=${osParam}`,
|
||||||
`arch=${archParam}`,
|
`arch=${arch}`,
|
||||||
`archive_type=${archiveType}`,
|
`archive_type=${archiveType}`,
|
||||||
`java_package_type=${bundleType}`,
|
`java_package_type=${bundleType}`,
|
||||||
`javafx_bundled=${javafx}`,
|
`javafx_bundled=${javafx}`,
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user