From b1ff4bb9fb38ca35e2c47cf1944c96284d0b7d22 Mon Sep 17 00:00:00 2001 From: Stephan Yelle Date: Sun, 5 Jan 2025 00:39:44 -0500 Subject: [PATCH] Update SVSTaskGate.ps1 --- SVSTaskGate.ps1 | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/SVSTaskGate.ps1 b/SVSTaskGate.ps1 index e7776d8..b6668de 100644 --- a/SVSTaskGate.ps1 +++ b/SVSTaskGate.ps1 @@ -864,21 +864,9 @@ try { } } - - - "/installrmm" { - if ($request.HttpMethod -eq "POST") { - # Parse the received JSON - $bodyStream = New-Object IO.StreamReader $request.InputStream - $body = $bodyStream.ReadToEnd() - $selectedSite = ConvertFrom-Json $body - Invoke-Expression $selectedSite.installRMMCommand - } - } - - <# + "/installrmm" { - if ($request.HttpMethod -eq "POST") { + if ($request.HttpMethod -eq "GET") { $bodyStream = New-Object IO.StreamReader $request.InputStream $body = $bodyStream.ReadToEnd() $selectedSite = ConvertFrom-Json $body @@ -924,7 +912,7 @@ try { } } -#> + "/setSVSPowerplan" { if ($request.HttpMethod -eq "GET") {