Conditions | 2 |
Paths | 2 |
Total Lines | 14 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Tests | 6 |
CRAP Score | 2.1481 |
Changes | 0 |
1 | <?php |
||
18 | 318 | public function connect(array $params, $username = null, $password = null, array $driverOptions = []) |
|
19 | { |
||
20 | try { |
||
21 | 318 | $conn = new PDOConnection( |
|
22 | 318 | $this->constructPdoDsn($params), |
|
23 | $username, |
||
24 | $password, |
||
25 | $driverOptions |
||
26 | ); |
||
27 | 213 | } catch (PDOException $e) { |
|
28 | 213 | throw DBALException::driverException($this, $e); |
|
29 | } |
||
30 | |||
31 | 318 | return $conn; |
|
32 | } |
||
71 |