Commit a3ecfa94 by Colin Howe

Pull $query when needed

parent 04c032da
# following PEP 386, versiontools will pick it up # following PEP 386, versiontools will pick it up
__version__ = (0, 1, 8, "final", 0) __version__ = (0, 1, 9, "final", 0)
...@@ -154,6 +154,9 @@ def _cursor_refresh(cursor_self): ...@@ -154,6 +154,9 @@ def _cursor_refresh(cursor_self):
query_data['collection'] = collection_name.full_name.split('.')[1] query_data['collection'] = collection_name.full_name.split('.')[1]
if query_data['collection'] == '$cmd': if query_data['collection'] == '$cmd':
# The query can be embedded within $query in some cases
query_son = query_son.get("$query", query_son)
query_data['operation'] = 'command' query_data['operation'] = 'command'
# Handle count as a special case # Handle count as a special case
if 'count' in query_son: if 'count' in query_son:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment