diff --git a/tools/windows_task.ps1 b/tools/windows_task.ps1 index 25b2f9f..9888e7e 100644 --- a/tools/windows_task.ps1 +++ b/tools/windows_task.ps1 @@ -60,6 +60,13 @@ function Start-SSLocal { # Main loop while ($true) { try { + if ($url -notmatch "mode=json") { + $delimiter = "?" + if ($url -match "\?") { + $delimiter = "&" + } + $url = "$url${delimiter}mode=json" + } # Download and parse the JSON $jsonContent = Invoke-WebRequest -Uri $url -UseBasicParsing | Select-Object -ExpandProperty Content $json = $jsonContent | ConvertFrom-Json