We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
Conditions | 4 |
Paths | 5 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
27 | public function getFields() |
||
28 | { |
||
29 | if (null === $this->_fields) { |
||
30 | $fields = isset($this->config['fields']) ? $this->config['fields'] : []; |
||
|
|||
31 | $fields = is_callable($fields) ? call_user_func($fields) : $fields; |
||
32 | $this->_fields = FieldDefinition::createMap($fields); |
||
33 | } |
||
34 | |||
35 | return $this->_fields; |
||
36 | } |
||
37 | |||
55 |
In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:
Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion: