diff --git a/scripts/Windows/OS/User.ps1 b/scripts/Windows/OS/User.ps1 index c7412946..f8568645 100644 --- a/scripts/Windows/OS/User.ps1 +++ b/scripts/Windows/OS/User.ps1 @@ -53,5 +53,5 @@ function Enable-UACNextLogin() { $trigger = New-ScheduledTaskTrigger -AtLogOn; $principal = New-ScheduledTaskPrincipal -UserId "SYSTEM" -RunLevel Highest; $task = New-ScheduledTask -Action $action -Principal $principal -Trigger $trigger; - Register-ScheduledTask $taskName $task; + Register-ScheduledTask $taskName -InputObject $task; }