Skip to content

Commit

Permalink
fixed bug in meridian choice when initializing with current time whil…
Browse files Browse the repository at this point in the history
…e the hour is 12 PM
  • Loading branch information
ycjoe committed Jun 15, 2012
1 parent de02883 commit 00803c7
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions js/bootstrap-timepicker.js
Expand Up @@ -137,8 +137,10 @@
if ( this.showMeridian ) {
if (hours === 0) {
hours = 12;
} else if (hours > 12) {
hours = hours - 12;
} else if (hours >= 12) {
if (hours > 12) {
hours = hours - 12;
}
meridian = "PM";
} else {
meridian = "AM";
Expand Down

0 comments on commit 00803c7

Please sign in to comment.