From 483c563526412f6e236696f84eb3dba55e7b816b Mon Sep 17 00:00:00 2001 From: Vencislav Atanasov Date: Wed, 30 Oct 2024 21:38:20 +0200 Subject: [PATCH] Fix array keys --- front-page-content.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/front-page-content.php b/front-page-content.php index 5ffbf71..08c1b45 100644 --- a/front-page-content.php +++ b/front-page-content.php @@ -13,11 +13,11 @@ if (!array_key_exists($blog_slug, $eventsConfig)) { $now = new DateTimeImmutable('now'); -$eventStart = new DateTimeImmutable($eventsConfig[$blog_slug]['eventStart'] . ' Europe/Sofia'); +$eventStart = new DateTimeImmutable($eventsConfig[$blog_slug]['startTime'] . ' Europe/Sofia'); $eventStartInterval = $now->diff($eventStart); $isBeforeEvent = $eventStartInterval instanceof DateInterval && $eventStartInterval->invert === 0; -$eventEnd = new DateTimeImmutable($eventsConfig[$blog_slug]['eventEnd'] . ' Europe/Sofia'); +$eventEnd = new DateTimeImmutable($eventsConfig[$blog_slug]['endTime'] . ' Europe/Sofia'); $eventEndInterval = $now->diff($eventEnd); $isAfterEvent = $eventEndInterval instanceof DateInterval && $eventEndInterval->invert === 1;