| Total Complexity | 4 |
| Total Lines | 37 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 13 | final class Unhealthy implements HealthCheck |
||
| 14 | { |
||
| 15 | use DependencyTrait; |
||
| 16 | use JsonSerializableTrait; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * @param DependencyStatus ...$dependencies |
||
| 20 | */ |
||
| 21 | public function __construct(DependencyStatus ...$dependencies) |
||
| 22 | { |
||
| 23 | $this->dependencies = new Set($dependencies); |
||
| 24 | } |
||
| 25 | |||
| 26 | /** |
||
| 27 | * @return iterable<DependencyStatus> |
||
| 28 | */ |
||
| 29 | public function __invoke(): iterable |
||
| 32 | } |
||
| 33 | |||
| 34 | /** |
||
| 35 | * @inheritDoc |
||
| 36 | */ |
||
| 37 | public function isHealthy(): bool |
||
| 38 | { |
||
| 39 | return false; |
||
| 40 | } |
||
| 41 | |||
| 42 | /** |
||
| 43 | * @return string |
||
| 44 | * @SuppressWarnings(PHPMD.UnusedPrivateMethod) Comes from the Trait which PHPMD cannot detect |
||
| 45 | * @psalm-return 'unhealthy' |
||
| 46 | */ |
||
| 47 | private function getStatus(): string |
||
| 50 | } |
||
| 51 | } |
||
| 52 |
This check looks for private methods that have been defined, but are not used inside the class.