Use date and mktime instead of cal_days_in_month to count a month's days

fixes #8637
This commit is contained in:
Johannes Meyer 2015-03-10 12:30:22 +01:00
parent b978fdb115
commit d0383a241e

View File

@ -268,7 +268,7 @@ class HistoryColorGrid extends AbstractWidget {
} }
$week++; $week++;
} }
if ($day > cal_days_in_month(CAL_GREGORIAN, $month, $year)) { if ($day > date('t', mktime(0, 0, 0, $month, 1, $year))) {
$month++; $month++;
if ($month > 12) { if ($month > 12) {
$year++; $year++;