From d2da8d3a507a3ebc287433a2972424b509cb4dae Mon Sep 17 00:00:00 2001 From: Vishal Bisht Date: Mon, 22 Jan 2024 20:16:37 +0530 Subject: [PATCH] [MM-56512] Impossible to set a custom reminder on the same day of following months (#25918) Co-authored-by: Mattermost Build --- .../channels/src/components/custom_status/date_time_input.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webapp/channels/src/components/custom_status/date_time_input.tsx b/webapp/channels/src/components/custom_status/date_time_input.tsx index 5af980c937..c322eaa6ce 100644 --- a/webapp/channels/src/components/custom_status/date_time_input.tsx +++ b/webapp/channels/src/components/custom_status/date_time_input.tsx @@ -92,7 +92,7 @@ const DateTimeInputContainer: React.FC = (props: Props) => { const setTimeAndOptions = () => { const currentTime = getCurrentMomentForTimezone(timezone); let startTime = moment(time).startOf('day'); - if (time.date() === currentTime.date()) { + if (currentTime.isSame(time, 'date')) { startTime = getRoundedTime(currentTime); } setTimeOptions(getTimeInIntervals(startTime));