| Conditions | 3 |
| Paths | 4 |
| Total Lines | 22 |
| Code Lines | 15 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 16 |
| CRAP Score | 3 |
| Changes | 0 | ||
| 1 | <?php |
||
| 20 | 28 | public function setData(Common\Dtos\AbstractDto $data): parent |
|
| 21 | { |
||
| 22 | // process address |
||
| 23 | 28 | if (isset($data->address)) { |
|
| 24 | 27 | $address = new AddressInternetType($this->dependenciesFactory); |
|
| 25 | 27 | $address |
|
| 26 | 27 | ->setDirectionalVariable($this->useOneDirectionalVariables) |
|
| 27 | 27 | ->setResolveOptions($this->resolveOptions) |
|
| 28 | 27 | ->setData($data->address); |
|
| 29 | 27 | $data->address = $address; |
|
| 30 | } |
||
| 31 | // process establishment |
||
| 32 | 28 | if (isset($data->establishment)) { |
|
| 33 | 1 | $establishment = new EstablishmentType($this->dependenciesFactory); |
|
| 34 | 1 | $establishment |
|
| 35 | 1 | ->setDirectionalVariable($this->useOneDirectionalVariables) |
|
| 36 | 1 | ->setResolveOptions($this->resolveOptions) |
|
| 37 | 1 | ->setData($data->establishment); |
|
| 38 | 1 | $data->establishment = $establishment; |
|
| 39 | } |
||
| 40 | |||
| 41 | 28 | return parent::setData($data); |
|
|
|
|||
| 42 | } |
||
| 52 |