Details
-
Bug
-
Resolution: Works as Designed
-
Major - P3
-
None
-
4.4.19, 6.0.5
-
None
-
Query Execution
-
ALL
-
Description
We've recently been writing a query to get back the index of an array item, however, it took us a while to realize that the index being returned was incorrect.
It seems that if the expression that you give to `$indexOfArray` has none existent values then the array index will be off by 1.
I'm not sure if this is by design but there's nothing in the documentation around this behavior.