Fix key name for reg load

This commit is contained in:
Manuel Thalmann 2023-06-25 17:57:06 +02:00
parent 972e1b6584
commit 294eb7839a

View file

@ -67,7 +67,7 @@ class Context {
[void] ProcessDefaultUserKey([System.Action[Microsoft.Win32.RegistryKey]] $action) {
$root = "HKLM:\DefaultUser";
$hivePath = "$env:SystemRoot\Profiles\Default User\NTUSER.dat"
$null = & reg load $root $hivePath;
$null = & reg load $root.Replace(":", "") $hivePath;
$action.Invoke((Get-Item $root));
}