Commit 9ca437d
committed
fix GenericReference iterable query (i.e.
This change adds the ``_ref`` or ``_ref.$id`` prefix to a query if all
values in an iterable query (i.e. ``__in``) are ``ObjectId``s or
``DBRef``s and raises an error for a mixed query which will only work
for documents. These could possibly be compiled into an ``{$or: ...}``
query, but the automatic expansion can be added as necessary.__in)1 parent e51ee40 commit 9ca437d
1 file changed
+20
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
129 | 129 | | |
130 | 130 | | |
131 | 131 | | |
| 132 | + | |
132 | 133 | | |
133 | 134 | | |
134 | 135 | | |
135 | 136 | | |
136 | 137 | | |
137 | 138 | | |
138 | 139 | | |
| 140 | + | |
139 | 141 | | |
140 | 142 | | |
141 | 143 | | |
| |||
144 | 146 | | |
145 | 147 | | |
146 | 148 | | |
147 | | - | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
148 | 153 | | |
149 | | - | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
150 | 158 | | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
151 | 169 | | |
152 | 170 | | |
153 | 171 | | |
| |||
0 commit comments