Closed Malix-Labs closed 11 months ago
Thanks for the issue @Malix-off, in this case the error message is actually correct-- although it's a little bit tricky. In this case Export-ModuleMember is not actually referencing the variable, it is just making available in the module space so while the name of the variable is used, the actual variable is not used. If you want to you can suppress this warning.
Prerequisites
Summary
PSScriptAnalyzer(PSUseDeclaredVarsMoreThanAssignments)
onExport-ModuleMember -Variable
PowerShell Version
Visual Studio Code Version
Extension Version
Steps to Reproduce
Visuals