You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@solr.apache.org by cp...@apache.org on 2024/01/31 10:59:00 UTC

(solr) branch branch_9x updated: NO JIRA: termVectors[NL] local variable rename in TermVectorComponent.process (#2234)

This is an automated email from the ASF dual-hosted git repository.

cpoerschke pushed a commit to branch branch_9x
in repository https://gitbox.apache.org/repos/asf/solr.git


The following commit(s) were added to refs/heads/branch_9x by this push:
     new d5101540b3e NO JIRA: termVectors[NL] local variable rename in TermVectorComponent.process (#2234)
d5101540b3e is described below

commit d5101540b3eef5caa4c7e9898eaf7da2d390102c
Author: Christine Poerschke <cp...@apache.org>
AuthorDate: Wed Jan 31 10:57:28 2024 +0000

    NO JIRA: termVectors[NL] local variable rename in TermVectorComponent.process (#2234)
    
    (cherry picked from commit 7d3683b007c9b6763a3bdb1805704865792f39f9)
---
 .../org/apache/solr/handler/component/TermVectorComponent.java | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/solr/core/src/java/org/apache/solr/handler/component/TermVectorComponent.java b/solr/core/src/java/org/apache/solr/handler/component/TermVectorComponent.java
index 5ef1571d403..6373b0a6337 100644
--- a/solr/core/src/java/org/apache/solr/handler/component/TermVectorComponent.java
+++ b/solr/core/src/java/org/apache/solr/handler/component/TermVectorComponent.java
@@ -130,8 +130,8 @@ public class TermVectorComponent extends SearchComponent {
       return;
     }
 
-    NamedList<Object> termVectors = new NamedList<>();
-    rb.rsp.add(TERM_VECTORS, termVectors);
+    NamedList<Object> termVectorsNL = new NamedList<>();
+    rb.rsp.add(TERM_VECTORS, termVectorsNL);
 
     IndexSchema schema = rb.req.getSchema();
     SchemaField keyField = schema.getUniqueKeyField();
@@ -236,7 +236,7 @@ public class TermVectorComponent extends SearchComponent {
       warnings.add("noPayloads", noPay);
     }
     if (warnings.size() > 0) {
-      termVectors.add(TV_KEY_WARNINGS, warnings);
+      termVectorsNL.add(TV_KEY_WARNINGS, warnings);
     }
 
     DocListAndSet listAndSet = rb.getResults();
@@ -268,10 +268,10 @@ public class TermVectorComponent extends SearchComponent {
         String uKey = schema.printableUniqueKey(solrDoc);
         assert null != uKey;
         docNL.add("uniqueKey", uKey);
-        termVectors.add(uKey, docNL);
+        termVectorsNL.add(uKey, docNL);
       } else {
         // support for schemas w/o a unique key,
-        termVectors.add("doc-" + docId, docNL);
+        termVectorsNL.add("doc-" + docId, docNL);
       }
 
       if (null != fields) {