| Conditions | 1 |
| Paths | 1 |
| Total Lines | 26 |
| Code Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 15 | public function filters() |
||
| 16 | { |
||
| 17 | return [ |
||
| 18 | [ |
||
| 19 | 'class' => '\Micro\Filter\AccessFilter', |
||
| 20 | 'actions' => ['index'], |
||
| 21 | 'rules' => [ |
||
| 22 | [ |
||
| 23 | 'allow' => false, |
||
| 24 | 'actions' => ['index'], |
||
| 25 | 'users' => ['?'], |
||
| 26 | 'message' => 'Only for authorized!' |
||
| 27 | ] |
||
| 28 | ] |
||
| 29 | ], |
||
| 30 | [ |
||
| 31 | 'class' => '\Micro\Filter\CsrfFilter', |
||
| 32 | 'actions' => ['index'] |
||
| 33 | ], |
||
| 34 | [ |
||
| 35 | 'class' => '\Micro\Filter\XssFilter', |
||
| 36 | 'actions' => ['index'], |
||
| 37 | 'clean' => '*' |
||
| 38 | ] |
||
| 39 | ]; |
||
| 40 | } |
||
| 41 | |||
| 68 |
If you access a property on an interface, you most likely code against a concrete implementation of the interface.
Available Fixes
Adding an additional type check:
Changing the type hint: