| Conditions | 3 |
| Paths | 2 |
| Total Lines | 6 |
| Code Lines | 3 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 32 | public function setPageObjectPath($toBeReplaced, $replace) |
||
| 33 | { |
||
| 34 | if (!empty($toBeReplaced) && !empty($replace)) { |
||
| 35 | $this->path = str_replace($toBeReplaced, $replace, $this->path); |
||
|
1 ignored issue
–
show
|
|||
| 36 | } |
||
| 37 | } |
||
| 38 | } |
||
| 39 |
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: