From baa50f4942b5bab86afce936aa6fee6edc72f3e4 Mon Sep 17 00:00:00 2001 From: Douglas Hammond Date: Wed, 14 Feb 2024 10:10:09 -0500 Subject: [PATCH] Update signatures with ibexa 4.6 changes --- lib/Container/Compiler/FieldType/RichTextIndexablePass.php | 2 +- lib/Core/Search/Solr/Handler.php | 2 ++ lib/Core/Search/Solr/ResultExtractor.php | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/Container/Compiler/FieldType/RichTextIndexablePass.php b/lib/Container/Compiler/FieldType/RichTextIndexablePass.php index 26ff3054..306e1be7 100644 --- a/lib/Container/Compiler/FieldType/RichTextIndexablePass.php +++ b/lib/Container/Compiler/FieldType/RichTextIndexablePass.php @@ -26,7 +26,7 @@ private function redefineIndexableImplementation(ContainerBuilder $container, $s $definition = $container->findDefinition(SearchField::class); $definition->setClass(IndexableRichText::class); - $definition->setArgument(0, $shortTextLimit); + $definition->setArguments([$shortTextLimit]); $definition->addTag('ibexa.field_type.indexable', ['alias' => 'ezrichtext']); $container->setDefinition(SearchField::class, $definition); diff --git a/lib/Core/Search/Solr/Handler.php b/lib/Core/Search/Solr/Handler.php index a49ec673..fb1c449e 100644 --- a/lib/Core/Search/Solr/Handler.php +++ b/lib/Core/Search/Solr/Handler.php @@ -31,6 +31,7 @@ public function findContent(Query $query, array $languageFilter = []): SearchRes $query->facetBuilders, $query->aggregations, $languageFilter, + $query->spellcheck, $query, ); } @@ -51,6 +52,7 @@ public function findLocations(LocationQuery $query, array $languageFilter = []): $query->facetBuilders, $query->aggregations, $languageFilter, + $query->spellcheck, $query, ); } diff --git a/lib/Core/Search/Solr/ResultExtractor.php b/lib/Core/Search/Solr/ResultExtractor.php index 855b4838..64f9c66d 100644 --- a/lib/Core/Search/Solr/ResultExtractor.php +++ b/lib/Core/Search/Solr/ResultExtractor.php @@ -5,6 +5,7 @@ namespace Netgen\IbexaSearchExtra\Core\Search\Solr; use Ibexa\Contracts\Core\Repository\Values\Content\Query; +use Ibexa\Contracts\Core\Repository\Values\Content\Query\Spellcheck; use Ibexa\Contracts\Core\Repository\Values\Content\Search\SearchResult; use Ibexa\Solr\ResultExtractor as BaseResultExtractor; use Netgen\IbexaSearchExtra\API\Values\Content\Search\LocationQuery as ExtraLocationQuery; @@ -28,6 +29,7 @@ public function extract( array $facetBuilders = [], array $aggregations = [], array $languageFilter = [], + ?Spellcheck $spellcheck = null, ?Query $query = null ): SearchResult { $searchResult = $this->extractSearchResult(