diff --git a/scripts/Windows/Scripts/Context.ps1 b/scripts/Windows/Scripts/Context.ps1 index 4425d1b3..d0d5d4e8 100644 --- a/scripts/Windows/Scripts/Context.ps1 +++ b/scripts/Windows/Scripts/Context.ps1 @@ -31,11 +31,6 @@ class Context { return Get-Item $this.ConfigRoot; } - [void] Set([string] $key, $value, [Microsoft.Win32.RegistryValueKind] $type) { - $configKey = $this.EnsureConfigKey(); - $configKey.SetValue($key, $value, $type); - } - [object] Get([string] $key) { $configKey = $this.EnsureConfigKey(); if ($configKey.GetValueNames().Contains($key)) { @@ -45,6 +40,16 @@ class Context { } } + [void] Set([string] $key, $value, [Microsoft.Win32.RegistryValueKind] $type) { + $configKey = $this.EnsureConfigKey(); + $configKey.SetValue($key, $value, $type); + } + + [void] Remove([string] $key) { + $configKey = $this.EnsureConfigKey(); + $configKey.DeleteValue($key); + } + [void] SetStage([string] $name) { $this.Set($this.StagePropertyName, $name, "ExpandString"); }