Conditions | 2 |
Paths | 2 |
Total Lines | 14 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 6 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php declare(strict_types=1); |
||
57 | public function toArray() : array |
||
58 | { |
||
59 | $result = [ |
||
60 | 'description' => $this->description, |
||
61 | 'deprecated' => $this->deprecated, |
||
62 | 'required' => $this->required, |
||
63 | 'allowEmptyValue' => $this->allowEmptyValue, |
||
64 | ]; |
||
65 | |||
66 | if (isset($this->schema)) { |
||
67 | $result['schema'] = $this->schema->toArray(); |
||
68 | } |
||
69 | |||
70 | return $result; |
||
71 | } |
||
73 |