diff --git a/src/DateUtils.js b/src/DateUtils.js index 79f5e1cfc0..56dd048945 100644 --- a/src/DateUtils.js +++ b/src/DateUtils.js @@ -55,6 +55,7 @@ function twelveHourTime(date) { let hours = date.getHours() % 12; const minutes = pad(date.getMinutes()); const ampm = date.getHours() >= 12 ? 'PM' : 'AM'; + hours = hours ? hours : 12; // convert 0 -> 12 return `${hours}:${minutes}${ampm}`; }