Skip to content

Commit

Permalink
Merge pull request #2683 from microsoft/dev
Browse files Browse the repository at this point in the history
fix issue in sort
  • Loading branch information
freddydk authored Sep 10, 2022
2 parents 824979a + aae37fa commit d87a5cc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion AppHandling/Sort-AppFilesByDependencies.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,10 @@ try {
$appName = [System.IO.Path]::GetFileName($files["$($_.id):$($_.version)"])
$app = $_
$installedApp = $excludeInstalledApps | Where-Object { $_.id -eq $app.id }
if ([System.Version]$app.Version -eq $installedApp.Version ) {
if (!$installedApp) {
$app
}
elseif ([System.Version]$app.Version -eq $installedApp.Version ) {
Write-Host "$appName is already installed with the same version"
}
elseif ([System.Version]$app.Version -lt $installedApp.Version ) {
Expand Down

0 comments on commit d87a5cc

Please sign in to comment.