Conditions | 2 |
Paths | 2 |
Total Lines | 14 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 2 |
Changes | 3 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
29 | 1 | public function compile(QueryBuilder $queryBuilder): string |
|
30 | { |
||
31 | 1 | $this->count = $queryBuilder->normalizeArgument($this->count, ['Number', 'Reference', 'Query', 'Bind']); |
|
32 | |||
33 | |||
34 | |||
35 | 1 | $output = 'LIMIT '; |
|
36 | 1 | if ($this->offset !== null) { |
|
37 | 1 | $this->offset = $queryBuilder->normalizeArgument($this->offset, ['Number', 'Reference', 'Query', 'Bind']); |
|
38 | |||
39 | 1 | $output .= $this->offset->compile($queryBuilder) . ', '; |
|
40 | } |
||
41 | |||
42 | 1 | return $output . $this->count->compile($queryBuilder); |
|
43 | } |
||
45 |