File tree 1 file changed +8
-0
lines changed
firebase-firestore/src/main/java/com/google/firebase/firestore/local 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change 23
23
import static java .lang .Math .max ;
24
24
25
25
import android .text .TextUtils ;
26
+ import android .util .Pair ;
27
+ import androidx .annotation .NonNull ;
26
28
import androidx .annotation .Nullable ;
27
29
import com .google .firebase .Timestamp ;
28
30
import com .google .firebase .database .collection .ImmutableSortedMap ;
@@ -476,13 +478,19 @@ public List<DocumentKey> getDocumentsMatchingTarget(Target target) {
476
478
477
479
List <String > subQueries = new ArrayList <>();
478
480
List <Object > bindings = new ArrayList <>();
481
+ List <Pair <Target , FieldIndex >> indexes = new ArrayList <>();
479
482
480
483
for (Target subTarget : getSubTargets (target )) {
481
484
FieldIndex fieldIndex = getFieldIndex (subTarget );
482
485
if (fieldIndex == null ) {
483
486
return null ;
484
487
}
488
+ indexes .add (Pair .create (subTarget , fieldIndex ));
489
+ }
485
490
491
+ for (Pair <Target , FieldIndex > pair : indexes ) {
492
+ Target subTarget = pair .first ;
493
+ @ NonNull FieldIndex fieldIndex = pair .second ;
486
494
@ Nullable List <Value > arrayValues = subTarget .getArrayValues (fieldIndex );
487
495
@ Nullable Collection <Value > notInValues = subTarget .getNotInValues (fieldIndex );
488
496
Bound lowerBound = subTarget .getLowerBound (fieldIndex );
You can’t perform that action at this time.
0 commit comments