-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 0.2.0
-
Component/s: None
-
None
This was previously discussed in PHPC-157 when consolidating the command and query result classes. Accessing the singular result document of a command should require the user to do $result->toArray()[0].
Currently, this method converts firstBatch from BSON to a zval (ignoring any custom type map in the process), which leads to inconsistent behavior between results for queries, commands that return a cursor, and commands that do not return a cursor.