Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
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>
  • Loading branch information
Claude and nbauma109 authored Apr 4, 2026
commit 3f583bc86a9b7e856a9b4a07457098f7dedc0951
3 changes: 1 addition & 2 deletions dist/setup/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -114787,12 +114787,11 @@ class ZuluDistribution extends base_installer_1.JavaBase {
console.time('Retrieving available versions for Zulu took'); // eslint-disable-line no-console
}
// Map old API parameters to new metadata API parameters
const archParam = hw_bitness === '64' ? arch : arch;
const osParam = this.getOsParam(platform);
const archiveType = this.getArchiveType(extension);
const requestArguments = [
`os=${osParam}`,
`arch=${archParam}`,
`arch=${arch}`,
`archive_type=${archiveType}`,
`java_package_type=${bundleType}`,
`javafx_bundled=${javafx}`,
Expand Down
3 changes: 1 addition & 2 deletions src/distributions/zulu/installer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,13 +113,12 @@ export class ZuluDistribution extends JavaBase {
}

// Map old API parameters to new metadata API parameters
const archParam = hw_bitness === '64' ? arch : arch;
const osParam = this.getOsParam(platform);
const archiveType = this.getArchiveType(extension);

const requestArguments = [
`os=${osParam}`,
`arch=${archParam}`,
`arch=${arch}`,
`archive_type=${archiveType}`,
`java_package_type=${bundleType}`,
`javafx_bundled=${javafx}`,
Expand Down