| 1 | <?php |
||
| 13 | class ErrorHandler extends \yii\web\ErrorHandler |
||
| 14 | { |
||
| 15 | /** |
||
| 16 | * @var string Event will be trigger before the ErrorHandler starts to render the exception. |
||
| 17 | */ |
||
| 18 | const EVENT_BEFORE_EXCEPTION_RENDER = 'onBeforeExceptionRender'; |
||
| 19 | |||
| 20 | use ErrorHandlerTrait { |
||
| 21 | renderException as protected traitRenderException; |
||
| 22 | } |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @inheritdoc |
||
| 26 | */ |
||
| 27 | public function renderException($exception) |
||
| 35 | } |
||
| 36 |
Our type inference engine has found a suspicous assignment of a value to a property. This check raises an issue when a value that can be of a given class or a super-class is assigned to a property that is type hinted more strictly.
Either this assignment is in error or an instanceof check should be added for that assignment.