api refactor: force access control and handle subpaths

Signed-off-by: Vladimir Mandic <mandic00@live.com>
This commit is contained in:
Vladimir Mandic
2025-02-14 11:25:29 -05:00
parent 877c488fa8
commit dbf20d1388
19 changed files with 92 additions and 45 deletions
+1 -1
View File
@@ -30,7 +30,7 @@ async function updateNVMLChart(mem, load) {
async function updateNVML() {
try {
const res = await fetch('/sdapi/v1/nvml');
const res = await fetch(`${window.api}/nvml`);
if (!res.ok) {
clearInterval(nvmlInterval);
nvmlEl.style.display = 'none';