Conditions | 2 |
Paths | 2 |
Total Lines | 9 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
23 | 26 | protected function checkValue($againstValue) |
|
24 | { |
||
25 | 26 | if (!is_array($againstValue)) { |
|
26 | 2 | throw new RuleException('No array found. Need set both values to compare!'); |
|
27 | } |
||
28 | 24 | $values = array_map([$this, 'checkRule'], $againstValue); |
|
29 | 22 | $lower = intval(min($values)); |
|
30 | 22 | $higher = intval(max($values)); |
|
31 | 22 | return [$lower, $higher]; |
|
32 | } |
||
50 |