From a6b3c33914453b6e0880ee32bc1bfdef9041de53 Mon Sep 17 00:00:00 2001 From: krogenth Date: Mon, 1 Jul 2024 20:32:26 -0400 Subject: [PATCH] fix [Nitpick] Account Link Code timer truncates leading zeroes. #108 --- src/views/dashboard/devices/DevicesRoot.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/dashboard/devices/DevicesRoot.vue b/src/views/dashboard/devices/DevicesRoot.vue index b75f5c2..d677f9b 100644 --- a/src/views/dashboard/devices/DevicesRoot.vue +++ b/src/views/dashboard/devices/DevicesRoot.vue @@ -131,7 +131,7 @@ export default { timerInterval = setInterval(() => { const left = this.$swal.getTimerLeft(); const minutes = Math.floor(left / 1000 / 60); - b.textContent = `${minutes}:${Math.floor(left / 1000 - minutes * 60)}`; + b.textContent = `${minutes}:${String(Math.floor(left / 1000 - minutes * 60)).padStart(2, '0')}`; }, 1000) }, willClose: () => {