Issue #2080551 by beowulf1416, deneo: Remove Unused local variable from /core/modules/search/lib/Drupal/search/SearchQuery.php.

8.0.x
webchick 2013-12-03 21:31:21 -08:00
parent 8f7e91cd74
commit cab8b6d5bc
1 changed files with 1 additions and 3 deletions

View File

@ -451,11 +451,9 @@ class SearchQuery extends SelectExtender {
// Re-normalize scores with multipliers by dividing by the total of all
// multipliers. The expressions were altered in addScore(), so here just
// add the arguments for the total.
$i = 0;
$sum = array_sum($this->multiply);
foreach ($this->multiply as $total) {
for ($i = 0; $i < count($this->multiply); $i++) {
$this->scoresArguments[':total_' . $i] = $sum;
$i++;
}
}