You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can solve this by editing the following functions in the original code:
`decrementHour: function() {
/* Added this line at the end*/
if (this.hour < 10) {this.hour = "0" + this.hour;}
},
incrementHour: function() {
/* Added this line at the end */
if (this.hour < 10) {this.hour = "0" + this.hour;}
},`
setTime: function(time, ignoreWidget) {
/* Added this line at the end */
if (hour < 10) {hour = "0" + hour;}
this.hour = hour;
this.minute = minute;
this.second = second;
this.meridian = meridian;
this.update(ignoreWidget);
},`
Is there any way to add leading zero to time?
For example: 1:30 => 01:30
The text was updated successfully, but these errors were encountered: