Skip to content

Commit a6b3c33

Browse files
committed
fix [Nitpick] Account Link Code timer truncates leading zeroes. OpenShock#108
1 parent b86b437 commit a6b3c33

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/views/dashboard/devices/DevicesRoot.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ export default {
131131
timerInterval = setInterval(() => {
132132
const left = this.$swal.getTimerLeft();
133133
const minutes = Math.floor(left / 1000 / 60);
134-
b.textContent = `${minutes}:${Math.floor(left / 1000 - minutes * 60)}`;
134+
b.textContent = `${minutes}:${String(Math.floor(left / 1000 - minutes * 60)).padStart(2, '0')}`;
135135
}, 1000)
136136
},
137137
willClose: () => {

0 commit comments

Comments
 (0)