We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 81a675d commit 65ecff9Copy full SHA for 65ecff9
src/lib/index.jsx
@@ -99,8 +99,8 @@ export default class CountdownTimer extends Component {
99
let hours = Math.floor(time / 3600) % 24;
100
let day = Math.floor(time / 86400);
101
day = day.toString().length === 1 ? `0${day}` : day;
102
- minutes = Number.parseInt(minutes.toString().length === 1 ? "0".concat(minutes) : minutes);
103
- seconds = Number.parseInt(seconds.toString().length === 1 ? "0".concat(seconds) : seconds);
+ minutes = minutes.toString().length === 1 ? `0${minutes}` : minutes;
+ seconds = seconds.toString().length === 1 ? `0${seconds}` : seconds;
104
hours = hours.toString().length === 1 ? `0${hours}` : hours;
105
if (showTitle) {
106
const borderClass = border ? 'border' : '';
0 commit comments