Conditions | 1 |
Paths | 1 |
Total Lines | 8 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
43 | private static function assertDivisor(int $divisor): void |
||
44 | { |
||
45 | match (true) { |
||
46 | 0 >= $divisor => throw new InvalidArgumentException('Divisor should be greater than 0.'), |
||
47 | $divisor > self::MAX_DIVISOR => throw new InvalidArgumentException( |
||
48 | sprintf('Divisor should be less than %s.', self::MAX_DIVISOR) |
||
49 | ), |
||
50 | default => null, |
||
51 | }; |
||
72 |