| Conditions | 3 | 
| Paths | 3 | 
| Total Lines | 13 | 
| Code Lines | 7 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 1 | ||
| Bugs | 0 | Features | 0 | 
| 1 | <?php  | 
            ||
| 6 | protected function setCachedOnlyProp($propName, $value)  | 
            ||
| 7 |     { | 
            ||
| 8 | if(in_array($propName, $this->cachedOnlyProps))  | 
            ||
| 
                                                                                                    
                        
                         | 
                |||
| 9 |         { | 
            ||
| 10 | if(!is_object($this->ldapObj))  | 
            ||
| 11 |             { | 
            ||
| 12 | $this->setFieldLocal($propName, $value);  | 
            ||
| 13 | return true;  | 
            ||
| 14 | }  | 
            ||
| 15 |             throw new \Exception('Unsupported!'); | 
            ||
| 16 | }  | 
            ||
| 17 | return false;  | 
            ||
| 18 | }  | 
            ||
| 19 | |||
| 45 | 
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: