quickfix broken setup_java

This commit is contained in:
CanbiZ
2025-11-13 10:17:51 +01:00
parent 4c717c3330
commit 5776f67afd

View File

@@ -2788,7 +2788,7 @@ function setup_java() {
# Validate INSTALLED_VERSION is not empty if matched # Validate INSTALLED_VERSION is not empty if matched
local JDK_COUNT=0 local JDK_COUNT=0
JDK_COUNT=$(dpkg -l 2>/dev/null | grep -c "temurin-.*-jdk") JDK_COUNT=$(dpkg -l 2>/dev/null | grep -c "temurin-.*-jdk" || true)
if [[ -z "$INSTALLED_VERSION" && "${JDK_COUNT:-0}" -gt 0 ]]; then if [[ -z "$INSTALLED_VERSION" && "${JDK_COUNT:-0}" -gt 0 ]]; then
msg_warn "Found Temurin JDK but cannot determine version" msg_warn "Found Temurin JDK but cannot determine version"
INSTALLED_VERSION="0" INSTALLED_VERSION="0"