Skip to content

Commit

Permalink
Fix missing cast in Get-ShouldOperator
Browse files Browse the repository at this point in the history
  • Loading branch information
fflaten committed May 18, 2024
1 parent 78e40a5 commit 65516ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/functions/Get-ShouldOperator.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
& $SafeCommands['Select-Object'] -Property Name, Alias |
& $SafeCommands['ForEach-Object'] { $_.Name; $_.Alias }

$ValidateSetAttribute = [System.Management.Automation.ValidateSetAttribute]::new($arrSet)
$ValidateSetAttribute = [System.Management.Automation.ValidateSetAttribute]::new([string[]]$arrSet)
$AttributeCollection.Add($ValidateSetAttribute)

$RuntimeParameter = [System.Management.Automation.RuntimeDefinedParameter]::new($ParameterName, [string], $AttributeCollection)
Expand Down

0 comments on commit 65516ef

Please sign in to comment.