From a55ed96f984f6c469769d238f1c68b1296886b24 Mon Sep 17 00:00:00 2001 From: lkassianik Date: Wed, 27 May 2015 17:21:18 -0700 Subject: [PATCH] Month views with two instances of the same month day number highlight both as 'today'. Summary: Fixes T8334, Month views with two instances of the same month day number highlight both as 'today'. Test Plan: Open May, only today 27th should be highlighted Reviewers: epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: Korvin, epriestley Maniphest Tasks: T8334 Differential Revision: https://secure.phabricator.com/D13044 --- src/view/phui/calendar/PHUICalendarMonthView.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/view/phui/calendar/PHUICalendarMonthView.php b/src/view/phui/calendar/PHUICalendarMonthView.php index 3adbe5eae7..d222450316 100644 --- a/src/view/phui/calendar/PHUICalendarMonthView.php +++ b/src/view/phui/calendar/PHUICalendarMonthView.php @@ -228,7 +228,8 @@ final class PHUICalendarMonthView extends AphrontView { $cell_day = null; } - if ($date && $date->format('j') == $this->day) { + if ($date && $date->format('j') == $this->day && + $date->format('m') == $this->month) { $today_class = 'phui-calendar-today-slot phui-calendar-today'; } else { $today_class = 'phui-calendar-today-slot';