| Total Complexity | 4 | 
| Total Lines | 34 | 
| Duplicated Lines | 0 % | 
| Changes | 1 | ||
| Bugs | 0 | Features | 0 | 
| 1 | <?php | ||
| 7 | class LabelsRequest implements RequestInterface | ||
| 8 | { | ||
| 9 | private $authentication; | ||
| 10 | |||
| 11 | private $trackingNumbers = []; | ||
| 12 | |||
| 13 | private $printInfo = []; | ||
| 14 | |||
| 15 | public function __construct(Authentication $authentication, array $trackingNumbers, string $printType, string $printFormat) | ||
| 22 | ]; | ||
| 23 | } | ||
| 24 | |||
| 25 | public function toArray(): array | ||
| 26 |     { | ||
| 27 | return array_merge( | ||
| 28 | $this->authentication->toArray(), | ||
| 29 | ['parcels' => $this->getTrackingNumbers(), 'printType' => $this->printInfo['type'], 'printFormat' => $this->printInfo['format']] | ||
| 30 | ); | ||
| 31 | } | ||
| 32 | |||
| 33 | public function getTrackingNumbers(): string | ||
| 36 | } | ||
| 37 | |||
| 38 | public function getCountry(): string | ||
| 41 | } | ||
| 42 | } | 
For hinted functions/methods where all return statements with the correct type are only reachable via conditions, ?null? gets implicitly returned which may be incompatible with the hinted type. Let?s take a look at an example: