Remove unnecessary config values
This commit is contained in:
parent
821db151cb
commit
8e4f0ccd9a
1 changed files with 3 additions and 0 deletions
|
@ -101,6 +101,7 @@ function Enable-UACNextLogin([Context] $context) {
|
||||||
"`$username = `$context.Get('$preparedUsernameProperty');",
|
"`$username = `$context.Get('$preparedUsernameProperty');",
|
||||||
"`$password = `$context.Get('$preparedPasswordProperty');",
|
"`$password = `$context.Get('$preparedPasswordProperty');",
|
||||||
"`$context.SetAutologin(`$username, `$password);",
|
"`$context.SetAutologin(`$username, `$password);",
|
||||||
|
"`$context.Remove('$preparedUsernameProperty');",
|
||||||
"`$context.Remove('$preparedPasswordProperty');")),
|
"`$context.Remove('$preparedPasswordProperty');")),
|
||||||
[System.Tuple]::Create(
|
[System.Tuple]::Create(
|
||||||
$uacDisablerTrigger,
|
$uacDisablerTrigger,
|
||||||
|
@ -109,6 +110,8 @@ function Enable-UACNextLogin([Context] $context) {
|
||||||
"Set-ItemProperty '$($key.PSPath)' -Name 'EnableLUA' -Value 0 -Type DWord;",
|
"Set-ItemProperty '$($key.PSPath)' -Name 'EnableLUA' -Value 0 -Type DWord;",
|
||||||
"Unregister-ScheduledTask -Confirm:`$false '$autoLoginName';",
|
"Unregister-ScheduledTask -Confirm:`$false '$autoLoginName';",
|
||||||
"Unregister-ScheduledTask -Confirm:`$false '$uacDisablerName';",
|
"Unregister-ScheduledTask -Confirm:`$false '$uacDisablerName';",
|
||||||
|
"`$context.Remove('$autoLoginTriggerProperty');",
|
||||||
|
"`$context.Remove('$uacDisablerTriggerProperty');",
|
||||||
". '$PSScriptRoot/../Scripts/Context.ps1';",
|
". '$PSScriptRoot/../Scripts/Context.ps1';",
|
||||||
"`$context = [Context]::new();",
|
"`$context = [Context]::new();",
|
||||||
"`$context.DeregisterNewUserReboot();",
|
"`$context.DeregisterNewUserReboot();",
|
||||||
|
|
Loading…
Reference in a new issue