Conditions | 2 |
Paths | 2 |
Total Lines | 10 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
14 | protected function insert($item, $value) |
||
15 | { |
||
16 | $direction = mb_strtolower($value); |
||
17 | if (!in_array($direction, [self::ASC, self::DESC])) { |
||
18 | throw new InvalidArgumentException( |
||
19 | sprintf("[OrderBy] Invalid direction (%s) for field (%s).", $direction, $item) |
||
20 | ); |
||
21 | } |
||
22 | |||
23 | parent::insert($item, $value); |
||
24 | } |
||
38 |