| Conditions | 3 |
| Paths | 4 |
| Total Lines | 8 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 5 |
| CRAP Score | 3 |
| Changes | 0 | ||
| 1 | <?php |
||
| 46 | 7 | public function __clone() |
|
| 47 | { |
||
| 48 | 7 | foreach ($this->joinColumns as $index => $joinColumn) { |
|
| 49 | 7 | $this->joinColumns[$index] = clone $joinColumn; |
|
| 50 | } |
||
| 51 | |||
| 52 | 7 | foreach ($this->inverseJoinColumns as $index => $inverseJoinColumn) { |
|
| 53 | 7 | $this->inverseJoinColumns[$index] = clone $inverseJoinColumn; |
|
| 54 | } |
||
| 57 |
This check marks implicit conversions of arrays to boolean values in a comparison. While in PHP an empty array is considered to be equal (but not identical) to false, this is not always apparent.
Consider making the comparison explicit by using
empty(..)or! empty(...)instead.