| Conditions | 3 |
| Paths | 3 |
| Total Lines | 16 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 26 | public static function getFromLimitString($from = null, $limit = null) |
||
| 27 | { |
||
| 28 | if ($limit !== null) { |
||
| 29 | $limitInt = (int) $limit; |
||
| 30 | $queryStr = ' LIMIT '.$limitInt; |
||
| 31 | |||
| 32 | if ($from !== null) { |
||
| 33 | $fromInt = (int) $from; |
||
| 34 | $queryStr .= ' OFFSET '.$fromInt; |
||
| 35 | } |
||
| 36 | |||
| 37 | return $queryStr; |
||
| 38 | } else { |
||
| 39 | return ''; |
||
| 40 | } |
||
| 41 | } |
||
| 42 | } |
||
| 43 |