We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
| Total Complexity | 8 |
| Total Lines | 27 |
| Duplicated Lines | 0 % |
| Coverage | 91.67% |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | class Sorted extends AbstractRule |
||
| 17 | { |
||
| 18 | public $fn = null; |
||
| 19 | public $ascending = true; |
||
| 20 | |||
| 21 | 7 | public function __construct(callable $fn = null, bool $ascending = true) |
|
| 22 | { |
||
| 23 | $this->fn = $fn ?? function ($x) { return $x; }; |
||
| 24 | 7 | $this->ascending = $ascending; |
|
| 25 | 7 | } |
|
| 26 | |||
| 27 | 7 | public function validate($input): bool |
|
| 43 | } |
||
| 44 | } |
||
| 45 |