mirror of https://github.com/apache/lucene.git
parent
c2125f331b
commit
974c9ac8d9
|
@ -324,6 +324,8 @@ class FacetFieldProcessorByArrayDV extends FacetFieldProcessorByArray {
|
|||
int ord = (toGlobal != null && segOrd >= 0) ? (int)toGlobal.get(segOrd) : segOrd;
|
||||
|
||||
int arrIdx = ord - startTermIndex;
|
||||
// This code handles faceting prefixes, which narrows the range of ords we want to collect.
|
||||
// It’s not an error for an ord to fall outside this range… we simply want to skip it.
|
||||
if (arrIdx >= 0 && arrIdx < nTerms) {
|
||||
countAcc.incrementCount(arrIdx, 1);
|
||||
if (collectAcc != null) {
|
||||
|
|
Loading…
Reference in New Issue