fix: do no display expired news items

This commit is contained in:
Julie Lenaerts 2023-11-20 15:51:07 +01:00
parent 13c33567fd
commit 50a6cb5af6

View File

@ -86,7 +86,7 @@ class NewsItemRepository implements ObjectRepository
$qb->expr()->andX(
$qb->expr()->lte('n.startDate', ':now'),
$qb->expr()->orX(
$qb->expr()->lt('n.endDate', ':now'),
$qb->expr()->gt('n.endDate', ':now'),
$qb->expr()->isNull('n.endDate')
)
)