Skip to content

Commit 17e85aa

Browse files
committed
attempt to get relay nested model retrieval
1 parent d93a9e1 commit 17e85aa

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

opensensor/collection_apis.py

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -221,17 +221,7 @@ def create_nested_pipeline(model: Type[BaseModel], prefix=""):
221221
nested_fields[field_name], "$$item."
222222
)
223223
pipeline[field_name] = {
224-
"$map": {
225-
"input": {
226-
"$filter": {
227-
"input": f"${full_field_name}",
228-
"as": "item",
229-
"cond": nested_match,
230-
}
231-
},
232-
"as": "item",
233-
"in": nested_pipeline,
234-
}
224+
"$map": {"input": f"${full_field_name}", "as": "item", "in": nested_pipeline}
235225
}
236226
match_conditions[full_field_name] = {"$exists": True, "$ne": []}
237227
else:

0 commit comments

Comments
 (0)