| Total Complexity | 5 |
| Total Lines | 30 |
| Duplicated Lines | 0 % |
| Coverage | 33.33% |
| Changes | 0 | ||
| 1 | <?php |
||
| 12 | final class PirateLogger implements PirateLoggerInterface |
||
| 13 | { |
||
| 14 | private ?Logger $logger = null; |
||
| 15 | |||
| 16 | 1 | public function __construct( |
|
| 17 | private Parser $parser |
||
| 18 | 1 | ) {} |
|
| 19 | |||
| 20 | 1 | #[Override] |
|
| 21 | public function init(): void |
||
| 22 | { |
||
| 23 | 1 | $this->logger = StuLogger::getLogger(LogTypeEnum::PIRATE); |
|
| 24 | } |
||
| 25 | |||
| 26 | #[Override] |
||
| 27 | public function log(string $message): void |
||
| 28 | { |
||
| 29 | if ($this->logger === null) { |
||
| 30 | throw new RuntimeException('logger has not been initialized'); |
||
| 31 | } |
||
| 32 | |||
| 33 | LogLevelEnum::INFO->log($this->parser->parse($message)->getAsText(), $this->logger); |
||
| 34 | } |
||
| 35 | |||
| 36 | #[Override] |
||
| 42 | )); |
||
| 43 | } |
||
| 44 | } |
||
| 45 |
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