| Conditions | 4 |
| Paths | 4 |
| Total Lines | 24 |
| Code Lines | 15 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 17 |
| CRAP Score | 4 |
| Changes | 0 | ||
| 1 | <?php |
||
| 21 | 1 | #[Override] |
|
| 22 | public function delete(UserInterface $user): void |
||
| 23 | { |
||
| 24 | 1 | foreach ($this->stationRepository->getStationsByUser($user->getId()) as $station) { |
|
| 25 | |||
| 26 | 1 | foreach ($station->getCrewAssignments() as $crewAssignment) { |
|
| 27 | |||
| 28 | 1 | $crew = $crewAssignment->getCrew(); |
|
| 29 | 1 | if ($crew->getUser() === $station->getUser()) { |
|
| 30 | 1 | continue; |
|
| 31 | } |
||
| 32 | |||
| 33 | 1 | $this->spacecraftLeaver->dumpCrewman( |
|
| 34 | 1 | $crewAssignment, |
|
| 35 | 1 | sprintf( |
|
| 36 | 1 | 'Die Dienste von Crewman %s werden nicht mehr auf der Station %s von Spieler %s benötigt.', |
|
| 37 | 1 | $crew->getName(), |
|
| 38 | 1 | $station->getName(), |
|
| 39 | 1 | $station->getUser()->getName(), |
|
| 40 | 1 | ) |
|
| 41 | 1 | ); |
|
| 42 | |||
| 43 | 1 | $this->entityManager->detach($crewAssignment); |
|
| 44 | 1 | $this->entityManager->detach($crew); |
|
| 45 | } |
||
| 49 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths