Issue #3173873 by shetpooja04: Unused variable $pos in SearchQuery.php, search module

merge-requests/25/head
Alex Pott 2020-10-02 13:03:18 +01:00
parent 70892a69f4
commit e0c3bb56f6
No known key found for this signature in database
GPG Key ID: 31905460D4A69276
1 changed files with 1 additions and 1 deletions

View File

@ -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++;