diff --git a/scripts/ValidateProjectVersionUpdated.ps1 b/scripts/ValidateProjectVersionUpdated.ps1 index 71e4230..6825a73 100644 --- a/scripts/ValidateProjectVersionUpdated.ps1 +++ b/scripts/ValidateProjectVersionUpdated.ps1 @@ -56,7 +56,8 @@ Catch { Exit 1 } -$currentPublishedVersion = [System.Management.Automation.SemanticVersion]$nugetIndex.items[0].upper +$currentPublishedVersion = $nugetIndex.items | Select-Object -ExpandProperty upper | ForEach-Object { [System.Management.Automation.SemanticVersion]$_ } | sort-object | Select-Object -Last 1 + # Validate that the version number has been updated. if ($currentProjectVersion -le $currentPublishedVersion) {