Skip to content

Commit c771df1

Browse files
committed
Closes #18 - fix validation
1 parent 0406644 commit c771df1

1 file changed

Lines changed: 2 additions & 6 deletions

File tree

src/private/BuildHelp.ps1

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,9 @@ function Build-Help {
1212
return
1313
}
1414

15-
#region Check PlatyPS version requirement
16-
$minVersion = [version]'1.0.1'
17-
$module = Get-Module -ListAvailable -Name Microsoft.PowerShell.PlatyPS | Sort-Object Version -Descending | Select-Object -First 1
18-
if (-not $module -or $module.Version -lt $minVersion) {
19-
throw 'Microsoft.PowerShell.PlatyPS version 1.0.1 or higher is required.'
15+
if (-not (Get-Module -Name Microsoft.PowerShell.PlatyPS -ListAvailable)) {
16+
throw 'The module Microsoft.PowerShell.PlatyPS must be installed for Markdown documentation to be generated.'
2017
}
21-
#endregion
2218

2319
$AllCommandHelpFiles = $helpMarkdownFiles | Measure-PlatyPSMarkdown | Where-Object FileType -Match CommandHelp
2420

0 commit comments

Comments
 (0)