Fix winget version check for versions 1.10 and higher

This commit is contained in:
Raphire
2025-02-25 22:49:25 +01:00
parent e1d397279f
commit a7f8cc38d9

View File

@@ -1064,7 +1064,7 @@ function DisplayCustomModeOptions {
# Check if winget is installed & if it is, check if the version is at least v1.4 # Check if winget is installed & if it is, check if the version is at least v1.4
if ((Get-AppxPackage -Name "*Microsoft.DesktopAppInstaller*") -and ((winget -v) -replace 'v','' -gt 1.4)) { if ((Get-AppxPackage -Name "*Microsoft.DesktopAppInstaller*") -and ([int](((winget -v) -replace 'v','').split('.')[0..1] -join '') -gt 14)) {
$global:wingetInstalled = $true $global:wingetInstalled = $true
} }
else { else {