#1952 - Event details page displays wrong date on events that occur 12am or later GMT
| Identifier | #1952 |
|---|---|
| Issue type | Minor issue (breaks specific functionality) |
| Title | Event details page displays wrong date on events that occur 12am or later GMT |
| Status | Completed |
| Handling member | PDStig |
| Addon | calendar |
| Description | When clicking an event to view its details, the details page will display the wrong date if the event occurs 12am or later GMT. All events on my website are set to GMT-4 hours, so any events that start 8pm or later ET will display a date that is one day sooner than the actual date they occur. |
| Steps to reproduce | 1. Create an event in the GMT-4 time zone and set the start time to occur 8pm or later. 2. Check the event details page for that event. 3. The event details will say the event starts one day sooner than the date you actually set it for. So say if you set it for Thursday May 7, it will say the event is on Wednesday May 6. |
| Funded? | No |
| Commits |
The system will post a comment when this issue is modified (e.g., status changes). To be notified of this, click "Enable comment notifications".


Comments
Is "Do timezone conversions" enabled for the event?
No recurrence settings set, correct?
(as if there were it would be an old file, as I don't think we've made one recently)
To check, go to integrity checker in /upgrader.php and make sure it doesn't report sources/calendar.php as corrupt/outdated.
Answering the above will just help me double check things, but I don't strictly need those answers.
Sorry it took ages to get to this one.
Do timezone conversions is off
These events do have recurrence (usually weekly).
sources/calendar.php does not show up in the file integrity check.
This fixes evening events in negative timezones (e.g. USA) so that links from the calendar don't then list the date in the wrong day.
As the calendar code in Composr is extremely complex this has been fixed by carefully adding a test case to our unit tests, and then ensuring all continue to pass.