From bf3befb5617272c276d652b80fcccc328436f92c Mon Sep 17 00:00:00 2001 From: Sergey Date: Fri, 3 Apr 2015 23:17:48 +0300 Subject: [PATCH] Docs small fix --- docs/commands.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/commands.md b/docs/commands.md index eb0aa092b..786ef2ec3 100644 --- a/docs/commands.md +++ b/docs/commands.md @@ -19,7 +19,7 @@ foreach($databases["databases"] as $database) { $listcollections = new MongoDB\Driver\Command(array("listCollections" => 1)); $retval = $manager->executeCommand($database->name, $listcollections); $collections = $retval->toArray(); - foreach($collections["collections"] as $collection) { + foreach($collections as $collection) { echo "\t- ", $collection->name, "\n"; } } @@ -53,7 +53,7 @@ $createuser = new MongoDB\Driver\Command($command); try { $result = $manager->executeCommand("admin", $createuser); $response = $result->toArray(); - if ($reponse["ok"]) { + if ($response["ok"]) { echo "User created\n"; } } catch(Exception $e) {