Skip to content

Commit 7ccbfce

Browse files
committed
Fix coding style according to StyleCI
1 parent a5e55c8 commit 7ccbfce

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/Jenssegers/Mongodb/Connection.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,10 +136,11 @@ protected function createConnection($dsn, array $config, array $options)
136136
$driverOptions = $config['driver_options'];
137137
}
138138

139-
if (!isset($options['username'])){
139+
// Check if the credentials are not already set in the options
140+
if (!isset($options['username'])) {
140141
$options['username'] = isset($config['username']) ? $config['username'] : '';
141142
}
142-
if (!isset($options['password'])){
143+
if (!isset($options['password'])) {
143144
$options['password'] = isset($config['password']) ? $config['password'] : '';
144145
}
145146

0 commit comments

Comments
 (0)