Skip to content

Commit 183f4de

Browse files
committed
Allow passing through of unbound positional parameters as-is
1 parent 03fd209 commit 183f4de

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/PSAppDeployToolkit.Tools/PSScriptAnalyzer/Measure-ADTCompatibility.psm1

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2731,6 +2731,11 @@ function Measure-ADTCompatibility
27312731
# This is a splatted parameter, e.g. @params, retain the original value
27322732
$NewParam = $boundParameter.Value.Value.Extent.Text
27332733
}
2734+
elseif ($boundParameter.Key -match '^\d+$')
2735+
{
2736+
# This is an unrecognized positional parameter, pass through as-is
2737+
$newParam = $boundParameter.Value.Value.Extent.Text
2738+
}
27342739
else
27352740
{
27362741
# This is a regular parameter, e.g. -Path 'xxx'

0 commit comments

Comments
 (0)