Skip to content

Commit

Permalink
Fix start date
Browse files Browse the repository at this point in the history
  • Loading branch information
m-pilarczyk committed May 18, 2023
1 parent 75b931b commit e3aeeda
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Repository/ArticleRepository.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ private function addFiltersToQueryBuilder(
}

if ($onlyPublished) {
$builder->andWhere('(a.type = :event OR a.startAt <= :now)');
$builder->andWhere('(a.type = :event OR a.startAt IS NULL OR a.startAt <= :now)');
$builder->setParameter('event', ArticleType::Event);
$builder->setParameter('now', new DateTimeImmutable());
}
Expand Down

0 comments on commit e3aeeda

Please sign in to comment.