Skip to content

Commit

Permalink
Fix php 8.0 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
MatthieuCutin committed Aug 11, 2021
1 parent bf83108 commit 064f15c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/QueryBuilder/ContainsNameQueryBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

use BitBag\SyliusElasticsearchPlugin\PropertyNameResolver\ConcatedNameResolverInterface;
use Elastica\Query\AbstractQuery;
use Elastica\Query\Match;
use Elastica\Query\MatchQuery;
use Sylius\Component\Locale\Context\LocaleContextInterface;

final class ContainsNameQueryBuilder implements QueryBuilderInterface
Expand Down Expand Up @@ -47,7 +47,7 @@ public function buildQuery(array $data): ?AbstractQuery
return null;
}

$nameQuery = new Match();
$nameQuery = new MatchQuery();

$nameQuery->setFieldQuery($propertyName, $name);
$nameQuery->setFieldFuzziness($propertyName, 2);
Expand Down

0 comments on commit 064f15c

Please sign in to comment.