@@ -60,14 +60,14 @@ discard block |
||
| 60 | 60 | public function getMongoDsnString() |
| 61 | 61 | { |
| 62 | 62 | $config = $this->getDatabaseConfiguration(); |
| 63 | - $dsn = 'mongodb://'; //[username:password@]host1[:port1][,host2[:port2],...[,hostN[:portN]]][/[database][?options]]'; |
|
| 63 | + $dsn = 'mongodb://'; //[username:password@]host1[:port1][,host2[:port2],...[,hostN[:portN]]][/[database][?options]]'; |
|
| 64 | 64 | $at = false; |
| 65 | 65 | if (!empty($config['username'])) { |
| 66 | 66 | $dsn .= $config['username']; |
| 67 | 67 | $at = true; |
| 68 | 68 | } |
| 69 | 69 | if (!empty($config['password'])) { |
| 70 | - $dsn .= ':'.$config['password']; |
|
| 70 | + $dsn .= ':' . $config['password']; |
|
| 71 | 71 | $at = true; |
| 72 | 72 | } |
| 73 | 73 | if ($at) { |
@@ -88,7 +88,7 @@ discard block |
||
| 88 | 88 | $config = $this->getDatabaseConfiguration(); |
| 89 | 89 | $dsn = $this->getMongoDsnString(); |
| 90 | 90 | $client = new Client($dsn); |
| 91 | - $collection = empty($config['table'])?Mongo::TABLE:$config['table']; |
|
| 91 | + $collection = empty($config['table']) ?Mongo::TABLE : $config['table']; |
|
| 92 | 92 | return new Mongo($client->selectCollection($config['database'], $collection)); |
| 93 | 93 | } |
| 94 | 94 | |