Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
D
drupal
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Custom Issue Tracker
Custom Issue Tracker
Labels
Merge Requests
302
Merge Requests
302
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Analytics
Analytics
Code Review
Insights
Issue
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
project
drupal
Commits
bf789fd1
Unverified
Commit
bf789fd1
authored
Oct 02, 2020
by
alexpott
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue
#3173873
by shetpooja04: Unused variable $pos in SearchQuery.php, search module
(cherry picked from commit
e0c3bb56
)
parent
326f5cc2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
core/modules/search/src/SearchQuery.php
core/modules/search/src/SearchQuery.php
+1
-1
No files found.
core/modules/search/src/SearchQuery.php
View file @
bf789fd1
...
...
@@ -520,7 +520,7 @@ public function addScore($score, $arguments = [], $multiply = FALSE) {
// 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
++
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment