1 | <?php declare(strict_types = 1); |
||
15 | class ErrorHandlerLogger extends Handler |
||
16 | { |
||
17 | |||
18 | /** |
||
19 | * Logger instance |
||
20 | * |
||
21 | * @var LoggerInterface |
||
22 | */ |
||
23 | protected $logger; |
||
24 | |||
25 | /** |
||
26 | * ErrorHandlerLogger constructor. |
||
27 | * |
||
28 | * @param LoggerInterface $logger |
||
|
|||
29 | */ |
||
30 | public function __construct(LoggerInterface $logger) |
||
34 | |||
35 | /** |
||
36 | * Logging exception |
||
37 | * |
||
38 | * @return int |
||
39 | */ |
||
40 | public function handle() |
||
51 | |||
52 | } |
This check looks for
@param
annotations where the type inferred by our type inference engine differs from the declared type.It makes a suggestion as to what type it considers more descriptive.
Most often this is a case of a parameter that can be null in addition to its declared types.