Fix case where changelog wasn't marked as invalid (#5726)
Co-authored-by: Wes Haggard <Wes.Haggard@microsoft.com>
This commit is contained in:
parent
247583f456
commit
e24c5f9900
@ -297,8 +297,8 @@ function Remove-EmptySections {
|
||||
{
|
||||
$parsedSections = $ChangeLogEntry.Sections
|
||||
$sanitizedReleaseContent = New-Object System.Collections.ArrayList(,$releaseContent)
|
||||
|
||||
foreach ($key in @($parsedSections.Keys))
|
||||
|
||||
foreach ($key in @($parsedSections.Keys))
|
||||
{
|
||||
if ([System.String]::IsNullOrWhiteSpace($parsedSections[$key]))
|
||||
{
|
||||
@ -442,9 +442,10 @@ function Confirm-ChangeLogForRelease {
|
||||
if (!$foundRecommendedSection)
|
||||
{
|
||||
$ChangeLogStatus.Message = "The changelog entry did not contain any of the recommended sections ($($RecommendedSectionHeaders -join ', ')), please add at least one. See https://aka.ms/azsdk/guideline/changelogs for more info."
|
||||
$ChangeLogStatus.IsValid = $false
|
||||
if (!$SuppressErrors) {
|
||||
LogError "$($ChangeLogStatus.Message)"
|
||||
}
|
||||
}
|
||||
return $ChangeLogStatus.IsValid
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user