| Conditions | 3 |
| Paths | 3 |
| Total Lines | 10 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 9 |
| CRAP Score | 3 |
| Changes | 2 | ||
| Bugs | 0 | Features | 2 |
| 1 | <?php |
||
| 23 | 2 | public function process(ListCitiesRequest $request,ListCitiesResponse $response){ |
|
| 24 | 2 | $cities = $this->userCityRepository->findAllByUsername($request->getUsername()); |
|
| 25 | 2 | if(count($cities) < 1){ |
|
| 26 | 1 | return; |
|
| 27 | } |
||
| 28 | 1 | foreach($cities as $city){ |
|
| 29 | 1 | $cityListView = new CityListView($city); |
|
| 30 | 1 | $response->addCity($cityListView); |
|
| 31 | 1 | } |
|
| 32 | } |
||
| 33 | } |