| Conditions | 5 |
| Paths | 16 |
| Total Lines | 21 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 11 |
| CRAP Score | 5 |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 28 | 8 | public function jsonSerialize(): array |
|
| 29 | { |
||
| 30 | 8 | $data = parent::jsonSerialize(); |
|
| 31 | |||
| 32 | 8 | if ($this->color !== null) { |
|
| 33 | 6 | $data['color'] = $this->color; |
|
| 34 | } |
||
| 35 | |||
| 36 | 8 | if ($this->horizontalOffset !== null) { |
|
| 37 | 4 | $data['horizontalOffset'] = $this->horizontalOffset; |
|
| 38 | } |
||
| 39 | |||
| 40 | 8 | if ($this->radius !== null) { |
|
| 41 | 5 | $data['radius'] = $this->radius; |
|
| 42 | } |
||
| 43 | |||
| 44 | 8 | if ($this->verticalOffset !== null) { |
|
| 45 | 4 | $data['verticalOffset'] = $this->verticalOffset; |
|
| 46 | } |
||
| 47 | |||
| 48 | 8 | return $data; |
|
| 49 | } |
||
| 51 |