summaryrefslogtreecommitdiffstats
path: root/modules-available/locationinfo
diff options
context:
space:
mode:
authorJannik Schönartz2017-12-07 17:29:02 +0100
committerJannik Schönartz2017-12-07 17:29:02 +0100
commiteffe85265f3fd58b14e979a4d24580347db3018a (patch)
treef2876679b7d301207e8bfab18f2d779bdb619e6c /modules-available/locationinfo
parent[locationinfo] Moved some shared functions to the frontendscript.js (diff)
downloadslx-admin-effe85265f3fd58b14e979a4d24580347db3018a.tar.gz
slx-admin-effe85265f3fd58b14e979a4d24580347db3018a.tar.xz
slx-admin-effe85265f3fd58b14e979a4d24580347db3018a.zip
[locationinfo] Cleared the old timeout before calling the new one.
Diffstat (limited to 'modules-available/locationinfo')
-rw-r--r--modules-available/locationinfo/templates/frontend-summary.html2
1 files changed, 2 insertions, 0 deletions
diff --git a/modules-available/locationinfo/templates/frontend-summary.html b/modules-available/locationinfo/templates/frontend-summary.html
index 9b375d4f..ec5d8aab 100644
--- a/modules-available/locationinfo/templates/frontend-summary.html
+++ b/modules-available/locationinfo/templates/frontend-summary.html
@@ -194,6 +194,7 @@
const ROOMUPDATE_MS = 2*60*1000;
const CALUPDATE_MS = 20*60*1000;
+ var timeout = null;
function update() {
var calendarUpdateIds = "";
@@ -228,6 +229,7 @@
for (property in rooms) {
upDateRoomState(rooms[property]);
}
+ clearTimeout(timeout);
setTimeout(update, nextUpdate);
}