diff --git a/apps/doztime/app-bangle2.js b/apps/doztime/app-bangle2.js index 1612ec4fd..9d1bb26c8 100644 --- a/apps/doztime/app-bangle2.js +++ b/apps/doztime/app-bangle2.js @@ -21,6 +21,7 @@ const time5 = {"size":42,"pt0":[39-g_x_off,24],"step":[26,0],"dx":-6.5,"dy":-6.5 const time6 = {"size":42,"pt0":[26-g_x_off,24],"step":[26,0],"dx":-6.5,"dy":-6.5}; // positioning for twinkling time line ft w 48, 48-g, step 30 const baseYear = 11584; const baseDate = Date(2020,11,21); // month values run from 0 to 11 +let calenDef = calen10; let accum = new Date(baseDate.getTime()); let sequence = []; let timeActiveUntil; @@ -169,20 +170,22 @@ function drawTime() let date = ""; let timeDef; let x = 0; + let time; + let wait; dt.setDate(dt.getDate()); if(addTimeDigit){ x = 10368*dt.getHours()+172.8*dt.getMinutes()+2.88*dt.getSeconds()+0.00288*dt.getMilliseconds(); let msg = "00000"+Math.floor(x).toString(12); - let time = msg.substr(-5,3)+"."+msg.substr(-2); //TODO: should `time` and `wait` have been defined outside the if block? - let wait = 347*(1-(x%1)); + time = msg.substr(-5,3)+"."+msg.substr(-2); //TODO: should `time` and `wait` have been defined outside the if block? + wait = 347*(1-(x%1)); timeDef = time6; } else { x = 864*dt.getHours()+14.4*dt.getMinutes()+0.24*dt.getSeconds()+0.00024*dt.getMilliseconds(); let msg = "0000"+Math.floor(x).toString(12); - let time = msg.substr(-4,3)+"."+msg.substr(-1); - let wait = 4167*(1-(x%1)); + time = msg.substr(-4,3)+"."+msg.substr(-1); + wait = 4167*(1-(x%1)); timeDef = time5; } if(lastX > x){ res = getDate(dt); } // calculate date once at start-up and once when turning over to a new day diff --git a/apps/lint_exemptions.js b/apps/lint_exemptions.js index 7f535bbc6..1bd285a9f 100644 --- a/apps/lint_exemptions.js +++ b/apps/lint_exemptions.js @@ -412,13 +412,6 @@ module.exports = { "no-unused-vars" ] }, - "apps/doztime/app-bangle2.js": { - "hash": "81592fe1bc6537f80d7dbe7b2e8145924d2400f98ea780c68dd5bd9694376c8a", - "rules": [ - "no-unused-vars", - "no-undef" - ] - }, "apps/devstopwatch/app.js": { "hash": "28ca59e605f280a2d8fd4a74f553783205d51f8bb7042d6f51cf8ec11d44c264", "rules": [