mirror of https://github.com/apache/lucene.git
LUCENE-7384: Tweak SpanWeight.buildSimWeight to reuse the existing similarity.
This commit is contained in:
parent
abb81e4ded
commit
180f9562aa
|
@ -99,7 +99,7 @@ public abstract class SpanWeight extends Weight {
|
|||
i++;
|
||||
}
|
||||
CollectionStatistics collectionStats = searcher.collectionStatistics(query.getField());
|
||||
return searcher.getSimilarity(true).computeWeight(boost, collectionStats, termStats);
|
||||
return similarity.computeWeight(boost, collectionStats, termStats);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue