Allow removing setup options

This commit is contained in:
Manuel Thalmann 2024-09-12 18:44:58 +02:00
parent 34d0eff73f
commit f0504b9960

View file

@ -346,8 +346,13 @@ $null = New-Module {
$Value
)
$key = Get-SetupConfigKey;
$null = Set-ItemProperty ($key.PSPath) -Name $Name -Value $Value;
$key = (Get-SetupConfigKey).PSPath;
if ($null -eq $Value) {
Remove-ItemProperty $key -Name $Name;
} else {
$null = Set-ItemProperty $key -Name $Name -Value $Value;
}
}
<#