Refactor variable declarations to use let instead

of var
This commit is contained in:
Andrew Malsbury
2023-11-17 18:30:43 +00:00
parent feea83d380
commit 955b7cc53b
2 changed files with 6 additions and 6 deletions

View File

@@ -128,7 +128,7 @@
function updateRunningTicketsCount() {
var runningTickets = parseInt(document.getElementById('runningTicketsCount').innerText, 10);
let runningTickets = parseInt(document.getElementById('runningTicketsCount').innerText, 10);
if (!isPaused && timerInterval) {
runningTickets += 1;
@@ -182,7 +182,7 @@
// Wait for other synchronous actions (if any) to complete before resetting the timer.
setTimeout(clearTimeStorage, 100); // 100ms delay should suffice, but you can adjust as needed.
});
try {
displayTime();
if (!localStorage.getItem(getLocalStorageKey("startTime")) && !localStorage.getItem(getLocalStorageKey("pausedTime"))) {