count caching
This commit is contained in:
parent
ae49740dfa
commit
68206097a7
|
@ -37,6 +37,14 @@ function setup() {
|
|||
};
|
||||
aM.appendChild(aB);
|
||||
},70*60*1000);
|
||||
let saved = window.localStorage.getItem("Count");
|
||||
if (saved > count)
|
||||
count = saved;
|
||||
document.body.onunload(()=>{
|
||||
let current = window.localStorage.getItem("Count");
|
||||
if (current < count)
|
||||
window.localStorage.setItem("Count", count);
|
||||
});
|
||||
}
|
||||
|
||||
socket.on('connected', (c, p) => {
|
||||
|
|
Loading…
Reference in New Issue
Block a user