| Conditions | 2 |
| Paths | 2 |
| Total Lines | 10 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 19 | public function handle(Query $query): Response |
||
| 20 | { |
||
| 21 | $key = $query->getKey(); |
||
| 22 | $profile = $query->getProfile(); |
||
| 23 | |||
| 24 | $unit = $this->repository->findUnit($key, $profile); |
||
| 25 | if (!is_null($unit)) { |
||
| 26 | return Response::createValidResponse($unit); |
||
| 27 | } else { |
||
| 28 | return Response::createInvalidResponse($query); |
||
| 29 | } |
||
| 32 |