Conditions | 2 |
Paths | 2 |
Total Lines | 14 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 6 |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
15 | public function assemble() |
||
16 | { |
||
17 | $query = "DELETE FROM {$this->getManager()->protect($this->getTable())}"; |
||
18 | |||
19 | $query .= $this->assembleWhere(); |
||
20 | |||
21 | $order = $this->parseOrder(); |
||
22 | if (!empty($order)) { |
||
23 | $query .= " order by {$order}"; |
||
24 | } |
||
25 | |||
26 | $query .= $this->assembleLimit(); |
||
27 | |||
28 | return $query; |
||
|
|||
29 | } |
||
31 |
In the issue above, the returned value is violating the contract defined by the mentioned interface.
Let's take a look at an example: