Skip to content

Commit

Permalink
Shows multiple events on the same day correctly
Browse files Browse the repository at this point in the history
Fixes SimpleMachines#7803

Signed-off-by: Jon Stovell <[email protected]>
  • Loading branch information
Sesquipedalian committed Aug 4, 2023
1 parent 32a5884 commit d9b2f3c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/Subs-Calendar.php
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ function getEventRange($low_date, $high_date, $use_permissions = true)
$start_date_string = date_format($start_object, 'Y-m-d');
$end_date_string = date_format($end_object, 'Y-m-d');

$cal_date = ($start_object >= $low_object) ? $start_object : $low_object;
$cal_date = ($start_object >= $low_object) ? (clone $start_object) : (clone $low_object);
while ($cal_date <= $end_object && $cal_date <= $high_object)
{
$starts_today = (date_format($cal_date, 'Y-m-d') == $start_date_string);
Expand Down

0 comments on commit d9b2f3c

Please sign in to comment.