It was unable to parse settings hashtable, when that hashtable has been wrapped as a PSObject. This started happening in PS 7.2, I was using Import-PowerShellDataFile to read some settings before passing them on to Invoke-ScriptAnalyzer.
There was some code to handle wrapped strings, might as well do that with all parameter types.
PR Summary
It was unable to parse settings hashtable, when that hashtable has been wrapped as a PSObject. This started happening in PS 7.2, I was using
Import-PowerShellDataFile
to read some settings before passing them on toInvoke-ScriptAnalyzer
.There was some code to handle wrapped strings, might as well do that with all parameter types.
PR Checklist
.cs
,.ps1
and.psm1
files have the correct copyright headerWIP:
to the beginning of the title and remove the prefix when the PR is ready.