| Conditions | 2 |
| Paths | 2 |
| Total Lines | 11 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | protected function generateCacheKey(): array |
||
| 22 | { |
||
| 23 | $cacheKey = []; |
||
|
|
|||
| 24 | |||
| 25 | if ($this->db instanceof ConnectionInterface) { |
||
| 26 | $cacheKey = [$this->db->getDriver()->getDsn(), $this->db->getDriver()->getUsername()]; |
||
| 27 | } else { |
||
| 28 | throw new NotSupportedException('Only PDO connections are supported.'); |
||
| 29 | } |
||
| 30 | |||
| 31 | return $cacheKey; |
||
| 32 | } |
||
| 34 |