make search keywords case insensitive

This commit is contained in:
ghost 2023-10-15 03:28:56 +03:00
parent a285aa3158
commit d0096cbfe2

View File

@ -76,6 +76,8 @@ class TorrentRepository extends ServiceEntityRepository
foreach ($keywords as $i => $keyword)
{
$keyword = mb_strtolower($keyword); // all keywords stored in lowercase
$orX->add("t.keywords LIKE :keyword{$i}");
$query->setParameter(":keyword{$i}", "%{$keyword}%");
}