Conditions | 2 |
Paths | 2 |
Total Lines | 17 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
24 | 2 | protected function triggerSpecific( |
|
25 | ShipWrapperInterface $wrapper, |
||
26 | FlightRouteInterface $flightRoute, |
||
27 | MessageCollectionInterface $messages |
||
28 | ): void { |
||
29 | |||
30 | 2 | $ship = $wrapper->get(); |
|
31 | |||
32 | 2 | if ($ship->getState() === ShipStateEnum::SHIP_STATE_ASTRO_FINALIZING) { |
|
33 | 1 | $message = new Message( |
|
34 | 1 | null, |
|
35 | 1 | $ship->getUser()->getId(), |
|
36 | 1 | [sprintf('Die %s hat die Kartographierung abgebrochen', $ship->getName())] |
|
37 | 1 | ); |
|
38 | 1 | $messages->add($message); |
|
39 | |||
40 | 1 | $this->astroEntryLib->cancelAstroFinalizing($ship); |
|
41 | } |
||
44 |