do not use an integer in a condition

This commit is contained in:
2023-11-29 21:03:03 +01:00
parent e2efb267f5
commit 6e48f8f7ea

View File

@@ -91,11 +91,11 @@ class NewsItemRepository implements ObjectRepository
{
$qb = $this->buildQueryCurrentNews();
if ($limit) {
if (null !== $limit) {
$qb->setMaxResults($limit);
}
if ($offset) {
if (null !== $offset) {
$qb->setFirstResult($offset);
}