Update SVSTaskGate.ps1

This commit is contained in:
2025-01-04 03:24:19 -05:00
parent a6b3b5b95f
commit 57cb5a78c0

View File

@@ -715,19 +715,7 @@ function GetHtmlContent {
method: 'POST', method: 'POST',
headers: { 'Content-Type': 'application/json' }, headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ installRMMCommand, UID, Name }) body: JSON.stringify({ installRMMCommand, UID, Name })
})
.then(response => {
if (!response.ok) {
appendLog(`Error: ${response.statusText}`, "red");
throw new Error(`Server responded with status ${response.status}`);
}
return response.text();
})
.then(data => {
appendLog(`Response: ${data}`, "green");
})
.catch(error => {
appendLog(`Fetch error: ${error.message}`, "red");
}); });
} }