diff --git a/core/modules/search/src/SearchQuery.php b/core/modules/search/src/SearchQuery.php index 08291e629668..ad451e81456c 100644 --- a/core/modules/search/src/SearchQuery.php +++ b/core/modules/search/src/SearchQuery.php @@ -521,7 +521,7 @@ class SearchQuery extends SelectExtender { // search expression. So, use string replacement to change this to a // calculated query expression, counting the number of occurrences so // in the execute() method we can add arguments. - while (($pos = strpos($score, 'i.relevance')) !== FALSE) { + while (strpos($score, 'i.relevance') !== FALSE) { $pieces = explode('i.relevance', $score, 2); $score = implode('((ROUND(:normalization_' . $this->relevance_count . ', 4)) * i.score * t.count)', $pieces); $this->relevance_count++;