From 1ada99b1d9370363f3065b4092dd5dc1ebd577fe Mon Sep 17 00:00:00 2001 From: Kevin Reynolds Date: Mon, 29 Apr 2024 12:22:02 -0400 Subject: [PATCH] js flailing --- labapp/app/templates/base.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/labapp/app/templates/base.html b/labapp/app/templates/base.html index 3fe868f..793608d 100644 --- a/labapp/app/templates/base.html +++ b/labapp/app/templates/base.html @@ -135,7 +135,7 @@ function fetchAndUpdateStatus() { let cachedStatus = getCookie('statusCache'); if (cachedStatus) { - document.getElementById('statusText').textContent = cachedStatus; + document.getElementById('siteName').textContent = cachedStatus['site_name']; } else { fetch('/_ce_status') .then(response => { @@ -145,9 +145,9 @@ return response.json(); }) .then(data => { - document.getElementById('statusText').textContent = data.status; + document.getElementById('siteName').textContent = data['site_name]']; // Cache the status in a cookie for 1 day - setCookie('statusCache', data.status, 1); + setCookie('statusCache', data.site_name, 1); }) .catch(error => { console.error('There was a problem with the fetch operation:', error); @@ -163,7 +163,7 @@ });
-

Status: Loading...

+

Status: Loading...

{% endif %}