PowerUp.ps1:2850 - Filter Out Null/Blank Output

Added "where-Object $_ -contains '\'" to prevent null or blank output from being passed to Get-ModifiablePath
This commit is contained in:
Bubbl3H3d 2017-10-01 15:04:25 -04:00 committed by GitHub
parent c7985c9bc3
commit 794a93e150
1 changed files with 1 additions and 1 deletions

View File

@ -2847,7 +2847,7 @@ function Get-ModifiableRegistryAutoRun {
$Path = $($Keys.GetValue($Name))
$Path | Get-ModifiablePath | ForEach-Object {
$Path | where-Object $_ -contains '\' | Get-ModifiablePath | ForEach-Object {
$Out = New-Object PSObject
$Out | Add-Member Noteproperty 'Key' "$ParentPath\$Name"
$Out | Add-Member Noteproperty 'Path' $Path