-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 1.2.0-alpha3
-
Component/s: None
-
None
Since ReadConcern and WriteConcern may be empty by default, it's possible for their bsonSerialize() methods to return an empty array. This will result in serialization to a BSON array, which would be rejected by the server. We should ensure an object is always returned from these methods.
This is not an issue for ReadPreference, since it will always contain at least a "mode" field; however, we can also return an object for good measure.
- is related to
-
PHPC-498 ReadPreference, ReadConcern, and WriteConcern should serialize to BSON
- Closed
- related to
-
PHPLIB-219 FindAndModify writeConcern option is sent as empty document
- Closed
-
PHPC-359 Ensure read preference tags sets serialize as documents
- Closed