From 2da7a25fcd199cbc972a49374dee5e519fda9f9d Mon Sep 17 00:00:00 2001 From: altaf-creator Date: Sun, 30 Nov 2025 19:12:43 +0700 Subject: quick fix --- frontend/main.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'frontend/main.js') diff --git a/frontend/main.js b/frontend/main.js index 1e1c8f9..e27977d 100644 --- a/frontend/main.js +++ b/frontend/main.js @@ -207,7 +207,6 @@ async function startLoadTimers() { prog.style.width = ((timeRemaining / (timers[i]["duration"] * 60)) * 100).toString() + "%"; if (timeRemaining <= 0) { - alert(`timer ${i} finished`); document.getElementById(`timer-btn-${i}`).disabled = false; } } @@ -228,6 +227,9 @@ async function finishLaundryTimer(timerId) { const response = await fetch(`${API_URL}/finish`, { method: "POST", credentials: "include", + headers: { + "Content-Type": "application/json" + }, body: JSON.stringify({id: timerId}), }); if (await response.text() == "laundry finished") { -- cgit v1.2.3