From ab73693a2be2757b4bf71e7b1e8a918c785c9dbd Mon Sep 17 00:00:00 2001 From: romanitho <96626929+Romanitho@users.noreply.github.com> Date: Thu, 23 Nov 2023 15:17:17 +0100 Subject: [PATCH] Roll Back notification task as system as it only works on SandBox --- Winget-AutoUpdate/functions/Start-NotifTask.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Winget-AutoUpdate/functions/Start-NotifTask.ps1 b/Winget-AutoUpdate/functions/Start-NotifTask.ps1 index 566b00c..326a40f 100644 --- a/Winget-AutoUpdate/functions/Start-NotifTask.ps1 +++ b/Winget-AutoUpdate/functions/Start-NotifTask.ps1 @@ -132,8 +132,8 @@ function Start-NotifTask { $ToastTemplate.toast.SetAttribute("launch", $OnClickAction) | Out-Null } - #if not "Interactive" user, run Winget-AutoUpdate-Notify scheduled task - if ($SessionID -eq 0) { + #if running as System, run Winget-AutoUpdate-Notify scheduled task + if ($IsSystem) { #Save XML to File $ToastTemplateLocation = "$($WAUConfig.InstallLocation)\config\"