Skip to content

Commit

Permalink
Checking the group id in csv
Browse files Browse the repository at this point in the history
  • Loading branch information
sima-zhu authored and azure-sdk committed Feb 2, 2022
1 parent 2ff5a4b commit 36fd741
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions eng/common/scripts/Update-DocsMsMetadata.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,10 @@ function GetPackageInfoJson ($packageInfoJsonLocation) {

function UpdateDocsMsMetadataForPackage($packageInfoJsonLocation, $packageInfo) {
$originalVersion = [AzureEngSemanticVersion]::ParseVersionString($packageInfo.Version)

$packageMetadataArray = (Get-CSVMetadata).Where({ $_.Package -eq $packageInfo.Name -and $_.GroupId -eq $packageInfo.Group -and $_.Hide -ne 'true' -and $_.New -eq 'true' })
$packageMetadataArray = (Get-CSVMetadata).Where({ $_.Package -eq $packageInfo.Name -and $_.Hide -ne 'true' -and $_.New -eq 'true' })
if ($packageMetadataArray.GroupId) {
$packageMetadataArray = ($packageMetadataArray).Where({$_.GroupId -eq $packageInfo.Group})
}
if ($packageMetadataArray.Count -eq 0) {
LogWarning "Could not retrieve metadata for $($packageInfo.Name) from metadata CSV. Using best effort defaults."
$packageMetadata = $null
Expand Down

0 comments on commit 36fd741

Please sign in to comment.