Skip to content

Commit 8df9587

Browse files
committed
Use ping instead of hello in docs
1 parent e479aa4 commit 8df9587

File tree

1 file changed

+4
-21
lines changed

1 file changed

+4
-21
lines changed

docs/reference/method/MongoDBDatabase-command.txt

Lines changed: 4 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ Errors/Exceptions
4343
Example
4444
-------
4545

46-
The following example executes a :manual:`hello
47-
</reference/command/hello>` command, which returns a cursor with a single
46+
The following example executes a :manual:`ping
47+
</reference/command/ping>` command, which returns a cursor with a single
4848
result document:
4949

5050
.. code-block:: php
@@ -53,32 +53,15 @@ result document:
5353

5454
$database = (new MongoDB\Client)->test;
5555

56-
$cursor = $database->command(['hello' => 1]);
56+
$cursor = $database->command(['ping' => 1]);
5757

5858
var_dump($c->toArray()[0]);
5959

6060
The output would resemble::
6161

6262
object(MongoDB\Model\BSONDocument)#11 (1) {
6363
["storage":"ArrayObject":private]=>
64-
array(8) {
65-
["isWritablePrimary"]=>
66-
bool(true)
67-
["maxBsonObjectSize"]=>
68-
int(16777216)
69-
["maxMessageSizeBytes"]=>
70-
int(48000000)
71-
["maxWriteBatchSize"]=>
72-
int(1000)
73-
["localTime"]=>
74-
object(MongoDB\BSON\UTCDateTime)#3 (1) {
75-
["milliseconds"]=>
76-
string(13) "1477608046464"
77-
}
78-
["maxWireVersion"]=>
79-
int(4)
80-
["minWireVersion"]=>
81-
int(0)
64+
array(1) {
8265
["ok"]=>
8366
float(1)
8467
}

0 commit comments

Comments
 (0)