iamsanjay commented on code in PR #2292:
URL: https://github.com/apache/solr/pull/2292#discussion_r1527174857


##########
solr/core/src/java/org/apache/solr/search/VectorSimilaritySourceParser.java:
##########
@@ -110,14 +146,38 @@ private ValueSource createSimilarityFunction(
     }
   }
 
-  private void requireVectorType(FieldType fieldType) throws SyntaxError {
-    if (!(fieldType instanceof DenseVectorField)) {
+  private DenseVectorField requireVectorType(final SchemaField field) throws 
SyntaxError {
+    final FieldType fieldType = field.getType();
+    if (fieldType instanceof DenseVectorField) {
+      return (DenseVectorField) field.getType();
+    }

Review Comment:
   +1 to return the Type as well. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to