From 2ceb708452410c38de716c44c6640e1956ea8814 Mon Sep 17 00:00:00 2001 From: Ryan Mwangi Date: Mon, 21 Oct 2024 15:22:43 +0300 Subject: [PATCH] remove refresh interval code from the client side --- script.js | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/script.js b/script.js index bd34422..e722e87 100644 --- a/script.js +++ b/script.js @@ -55,18 +55,4 @@ const form = document.getElementById('merge-form'); console.error('Error:', error); result.innerHTML = `Error merging calendars: ${error.message}` }); - }); - - const refreshInterval = 60 * 60 * 1000; // 1 hour - setInterval(() => { - fetch('/merge') - .then((response) => response.json()) - .then((data) => { - result.innerHTML = `Merged calendar URL: ${data.url}`; - }) - .catch((error) => { - console.error(error); - result.innerHTML = 'Error merging calendars'; - }); - }, refreshInterval); - \ No newline at end of file + }); \ No newline at end of file