We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents e7862df + 18d16f2 commit 82755c9Copy full SHA for 82755c9
1 file changed
Classes/Controller/SuggestController.php
@@ -93,7 +93,8 @@ protected function buildRequestForTerm($contextNodeIdentifier, $dimensionCombina
93
$term = strtolower($term);
94
95
// The suggest function only works well with one word
96
- $suggestTerm = explode(' ', $term)[0];
+ // and the term is trimmed to alnum characters to avoid errors
97
+ $suggestTerm = preg_replace('/[[:^alnum:]]/', '', explode(' ', $term)[0]);
98
99
if(!$this->elasticSearchQueryTemplateCache->has($cacheKey)) {
100
$contentContext = $this->createContentContext('live', json_decode($dimensionCombination, true));
0 commit comments