Fixed user run from system task
parent
e6dcb70a58
commit
31732404f6
|
@ -165,7 +165,7 @@ if ($IsSystem) {
|
||||||
$UserScheduledTask = Get-ScheduledTask -TaskName "Winget-AutoUpdate-UserContext" -ErrorAction SilentlyContinue
|
$UserScheduledTask = Get-ScheduledTask -TaskName "Winget-AutoUpdate-UserContext" -ErrorAction SilentlyContinue
|
||||||
if ($UserScheduledTask){
|
if ($UserScheduledTask){
|
||||||
Write-Log "Starting WAU in User context"
|
Write-Log "Starting WAU in User context"
|
||||||
Start-ScheduledTask $UserScheduledTask -ErrorAction SilentlyContinue
|
Start-ScheduledTask $UserScheduledTask.TaskName -ErrorAction SilentlyContinue
|
||||||
Exit 0
|
Exit 0
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
Loading…
Reference in New Issue