| Conditions | 3 |
| Paths | 3 |
| Total Lines | 15 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 10 |
| CRAP Score | 3 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 15 | */ |
||
| 16 | 11 | public function getRelatedPartyAccount(SimpleXMLElement $xmlRelatedPartyTypeAccount) |
|
| 17 | { |
||
| 18 | 11 | if (false === isset($xmlRelatedPartyTypeAccount->Id)) { |
|
| 19 | return; |
||
| 20 | } |
||
| 21 | |||
| 22 | 11 | if (isset($xmlRelatedPartyTypeAccount->Id->IBAN) && $ibanCode = (string) $xmlRelatedPartyTypeAccount->Id->IBAN) { |
|
| 23 | 10 | return new DTO\IbanAccount(new Iban($ibanCode)); |
|
| 24 | } |
||
| 25 | |||
| 26 | 6 | if (false === isset($xmlRelatedPartyTypeAccount->Id->Othr)) { |
|
| 27 | return; |
||
| 28 | } |
||
| 29 | |||
| 30 | 6 | $xmlOtherIdentification = $xmlRelatedPartyTypeAccount->Id->Othr; |
|
| 50 |