Conditions | 3 |
Paths | 3 |
Total Lines | 10 |
Code Lines | 4 |
Lines | 0 |
Ratio | 0 % |
Tests | 5 |
CRAP Score | 3 |
Changes | 0 |
1 | <?php |
||
34 | 2 | public static function networkByCoinShortcut(string $shortcut, Features $coinTypes) |
|
35 | { |
||
36 | 2 | foreach ($coinTypes->getCoinsList() as $coinType) { |
|
37 | /** @var CoinType $coinType */ |
||
38 | 2 | if ($coinType->getCoinShortcut() === $shortcut) { |
|
39 | 2 | return $coinType; |
|
40 | } |
||
41 | } |
||
42 | |||
43 | 1 | return null; |
|
44 | } |
||
46 |