Conditions | 2 |
Paths | 2 |
Total Lines | 10 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Tests | 6 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
40 | 2 | protected static function build( $connection ) { |
|
41 | 2 | $connections = static::connections(); |
|
42 | |||
43 | 2 | if ( empty( $connections[ $connection ] ) ) { |
|
44 | 1 | throw new ConnectionNotFoundException(); |
|
45 | } |
||
46 | |||
47 | 1 | static::$instances[ $connection ] = new Queue( $connections[ $connection ] ); |
|
48 | |||
49 | 1 | return static::$instances[ $connection ]; |
|
50 | } |
||
66 | } |