Skip to content

Commit

Permalink
Update ThemeTable.php
Browse files Browse the repository at this point in the history
Set the limit 1 on fetching themes by anr and label.
  • Loading branch information
Ruslan Baidan authored Nov 24, 2022
1 parent 14affb0 commit 1bbd96d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Model/Table/ThemeTable.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public function findByAnrIdAndLabel(?int $anrId, string $labelKey, string $label
return $queryBuilder
->andWhere('t.' . $labelKey . ' = :' . $labelKey)
->setParameter($labelKey, $labelValue)
->setMaxResults(1)
->getQuery()
->getOneOrNullResult();
}
Expand Down

0 comments on commit 1bbd96d

Please sign in to comment.