Allow removing setup options

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

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;
}
}
<#