From cb9ac51f6c2bc665b5f080d7c284044d068ca3d5 Mon Sep 17 00:00:00 2001 From: Klaus Dandl <76051010+Utesgui@users.noreply.github.com> Date: Fri, 10 May 2024 22:02:50 +0000 Subject: [PATCH] refactor: Trim product version in Update-SmartProjects.IsoBuster.ps1 The `Update-SmartProjects.IsoBuster.ps1` script has been modified to trim the product version retrieved from the file. This change ensures that any leading or trailing whitespace is removed from the version information. --- Scripts/Update-SmartProjects.IsoBuster.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Scripts/Update-SmartProjects.IsoBuster.ps1 b/Scripts/Update-SmartProjects.IsoBuster.ps1 index 9a114de..fc5dae9 100644 --- a/Scripts/Update-SmartProjects.IsoBuster.ps1 +++ b/Scripts/Update-SmartProjects.IsoBuster.ps1 @@ -16,7 +16,7 @@ $latestVersionUrl = $url -split " " | Select-Object -First 1 $DownloadFileName = "IsoBuster_installer.exe" Invoke-WebRequest -Uri $latestVersionUrl -OutFile $DownloadFileName $file = Get-ChildItem -Path $DownloadFileName -$versionInfo = $file.VersionInfo.ProductVersion +$versionInfo = $file.VersionInfo.ProductVersion.trim() if ($null -eq $versionInfo) { Write-Host "Could not find version info in file"