Conditions | 4 |
Paths | 4 |
Total Lines | 15 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
14 | public function canSolve(Throwable $throwable): bool |
||
15 | { |
||
16 | if ($this->canTryDatabaseConnection()) { |
||
17 | try { |
||
18 | DB::connection()->select('SELECT 1'); |
||
19 | } catch (\Exception $e) { |
||
20 | |||
21 | if ($this->isUnknownDatabaseCode($e->getCode())) { |
||
22 | return in_array(env('DB_DATABASE'), ['homestead', 'laravel']); |
||
23 | } |
||
24 | } |
||
25 | } |
||
26 | |||
27 | return false; |
||
28 | } |
||
29 | |||
45 |