| Conditions | 2 |
| Paths | 4 |
| Total Lines | 11 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | public function __invoke($request, $response, $args) |
||
| 22 | { |
||
| 23 | try { |
||
| 24 | $this->setParams($request, $response, $args); |
||
| 25 | $result = $this->getTaskService()->searchTasks($this->args['query']); |
||
| 26 | |||
| 27 | return $this->jsonResponse('success', $result, 200); |
||
| 28 | } catch (\Exception $ex) { |
||
| 29 | return $this->jsonResponse('error', $ex->getMessage(), $ex->getCode()); |
||
| 30 | } |
||
| 31 | } |
||
| 32 | } |
||
| 33 |