| 1 | <?php |
||
| 12 | class AntiXssExtension extends \Twig_Extension |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * @var array |
||
| 16 | */ |
||
| 17 | private $options = [ |
||
| 18 | 'is_safe' => ['html'], |
||
| 19 | 'needs_environment' => false, |
||
| 20 | ]; |
||
| 21 | |||
| 22 | /** |
||
| 23 | * @var callable |
||
| 24 | */ |
||
| 25 | private $callable; |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @var AntiXss |
||
| 29 | */ |
||
| 30 | private $antiXss; |
||
| 31 | |||
| 32 | /** |
||
| 33 | * AntiXssExtension constructor. |
||
| 34 | * |
||
| 35 | * @param AntiXSS $antiXss |
||
| 36 | */ |
||
| 37 | 6 | public function __construct(AntiXSS $antiXss) |
|
| 42 | |||
| 43 | /** |
||
| 44 | * @param string $html |
||
| 45 | * |
||
| 46 | * @return mixed |
||
| 47 | */ |
||
| 48 | 6 | public function xss_clean($html) |
|
| 52 | |||
| 53 | /** @noinspection PhpMissingParentCallCommonInspection */ |
||
| 54 | /** |
||
| 55 | * @return array |
||
| 56 | */ |
||
| 57 | 6 | public function getFilters(): array |
|
| 63 | |||
| 64 | /** @noinspection PhpMissingParentCallCommonInspection */ |
||
| 65 | 6 | public function getFunctions(): array |
|
| 71 | |||
| 72 | /** @noinspection PhpMissingParentCallCommonInspection */ |
||
| 73 | 6 | public function getTokenParsers(): array |
|
| 79 | } |
||
| 80 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..