Fixes #7037 -- Fix CarbonImmutable error on stats overview page.

This commit is contained in:
Buster Neece 2024-04-17 01:06:39 -05:00
parent bee576b5e7
commit 08c5468562
No known key found for this signature in database
1 changed files with 2 additions and 4 deletions

View File

@ -65,8 +65,7 @@ final class ChartsAction extends AbstractReportAction
$daysOfWeek = [];
foreach ($dailyStats as $stat) {
/** @var CarbonImmutable $statTime */
$statTime = $stat['moment'];
$statTime = CarbonImmutable::instance($stat['moment']);
$statTime = $statTime->shiftTimezone($stationTz);
$avgRow = new stdClass();
@ -175,8 +174,7 @@ final class ChartsAction extends AbstractReportAction
}
foreach ($hourlyStats as $stat) {
/** @var CarbonImmutable $statTime */
$statTime = $stat['moment'];
$statTime = CarbonImmutable::instance($stat['moment']);
$statTime = $statTime->shiftTimezone($stationTz);
$hour = $statTime->hour;