sched: wait before reloading to avoid `load()` output

pull/2782/head
Rob Pilling 2023-05-29 15:53:07 +01:00
parent 81e810bcd7
commit f8d1de16ce
1 changed files with 3 additions and 1 deletions

View File

@ -89,7 +89,9 @@ function upload() {
Util.showModal("Saving...");
Util.writeStorage("sched.json", JSON.stringify(alarms), () => {
Puck.write(`\x10load()\n`, () => { // reload watch to load alarms
location.reload(); // reload so we see current data
setTimeout(() => {
location.reload(); // reload so we see current data
}, 500);
});
});
}