Skip to content

Commit

Permalink
Corrected null check for excludeRule param
Browse files Browse the repository at this point in the history
  • Loading branch information
spetersenms committed Jan 20, 2025
1 parent e55aecc commit 2dd2be3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Actions/RunPSScriptAnalyzer/RunPSScriptAnalyzer.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Import-Module -Name ConvertToSARIF -Force

$htPSA = [ordered]@{ Path = $Path }
Write-Output "Modules installed, now running tests."
if (![string]::IsNullOrEmpty($ExcludeRule)) { $htPSA.add('ExcludeRule', $ExcludeRule) }
if ($ExcludeRule) { $htPSA.add('ExcludeRule', $ExcludeRule) }
if ($Recurse) { $htPSA.add('Recurse', $true) }
$htCTS = [ordered]@{ FilePath = $Output }

Expand Down

0 comments on commit 2dd2be3

Please sign in to comment.