diff --git a/core/modules/search/lib/Drupal/search/SearchQuery.php b/core/modules/search/lib/Drupal/search/SearchQuery.php index 668ca14..8e5f803 100644 --- a/core/modules/search/lib/Drupal/search/SearchQuery.php +++ b/core/modules/search/lib/Drupal/search/SearchQuery.php @@ -443,7 +443,8 @@ public function execute() // Format the float to make sure that the decimal separator is a period // no matter what the numeric locale is set to. This is so the database - // query will not fail. + // query will not fail because a float with a comma is handed to MySQL as a + // number to do calculations on. $relevance = number_format((1.0 / $this->normalize), 10, '.', ''); // Replace i.relevance pseudo-field with the actual, normalized value. $this->scores = str_replace('i.relevance', '(' . $relevance . ' * i.score * t.count)', $this->scores);