PHP-1160: Omit empty query hashes from count commands

When calling MongoCollection::count() with an empty $query argument, an empty array would be serialized as a BSON array and trigger a validation error on MongoDB 2.7.7. If the $query argument is an empty hash, simply omit it from the command.

This is generally not a problem for MongoCursor::count(), since its constructor detects an empty query argument; however, it could still happen if the query is modified after the fact.

Note: SERVER-15456 relaxed validation of the query option in 2.7.8, but it shouldn't hurt to have these precautions in the driver.