Conditions | 3 |
Paths | 3 |
Total Lines | 14 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 3 |
Changes | 10 | ||
Bugs | 2 | Features | 6 |
1 | <?php |
||
56 | 18 | public function render($type = null) |
|
57 | 3 | { |
|
58 | 18 | $templates = new Engine($this->viewPath); |
|
59 | |||
60 | 18 | if ($type === null) { |
|
61 | 12 | if ($this->media === false) { |
|
62 | 9 | $type = 'media'; |
|
63 | 9 | } else { |
|
64 | 3 | $type = 'thumbnail'; |
|
65 | } |
||
66 | 12 | } |
|
67 | |||
68 | 18 | return $templates->render($type, $this->toArray()); |
|
69 | } |
||
70 | |||
103 |
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..