sabi0 commented on PR #12965: URL: https://github.com/apache/lucene/pull/12965#issuecomment-1867009056
It seems the method could be skipped completely if the query does not contain `fieldName` or `defaultField`: ``` protected void extractWeightedSpanTerms(Map<String,WeightedSpanTerm> terms, SpanQuery spanQuery, float boost) throws IOException { Set<String> queryFieldNames = new HashSet<>(); collectSpanQueryFields(spanQuery, queryFieldNames); if (fieldName != null && !queryFieldNames.contains(fieldName) && (defaultField == null || !queryFieldNames.contains(defaultField))) { return; } ``` Should I add this to the PR? -- 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: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org