| Conditions | 1 |
| Paths | 1 |
| Total Lines | 8 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 14 | public function createFromEntityManager(EntityManagerInterface $entityManager): \mysqli |
||
| 15 | { |
||
| 16 | $params = $entityManager->getConnection()->getParams(); |
||
| 17 | |||
| 18 | $conn = new \mysqli($params['host'], $params['user'], $params['password'], $params['dbname']); |
||
| 19 | mysqli_report(MYSQLI_REPORT_ERROR | MYSQLI_REPORT_STRICT); |
||
| 20 | |||
| 21 | return $conn; |
||
| 22 | } |
||
| 24 |