feat: Simplify getVersions function (#2112)

This commit is contained in:
Kroese
2026-08-08 05:13:33 +02:00
committed by GitHub
parent 5c213770ad
commit eb2207dff9
+6 -7
View File
@@ -99,16 +99,15 @@ getVersions() {
structured="" structured=""
case "${candidate_base,,}" in case "${candidate_base,,}" in
"winvista"* | "win7"* | "win8"* | "win10"* | "win11"* )
structured=$(normalizeEditionID "${edition_id:-${flags:-}}" "$candidate_base") || return 1 "win20"* ) structured=$(normalizeServerEditionID "${flags:-$edition_id}") || return 1
;;
"win20"* )
structured=$(normalizeServerEditionID "${flags:-$edition_id}") || return 1
if [[ "${install_type,,}" == *"core"* && "$structured" != *"-core" ]]; then if [[ "${install_type,,}" == *"core"* && "$structured" != *"-core" ]]; then
structured+="-core" structured+="-core"
fi fi ;;
;;
* ) structured=$(normalizeEditionID "${edition_id:-${flags:-}}" "$candidate_base") || return 1 ;;
esac esac
if [ -n "$structured" ]; then if [ -n "$structured" ]; then