| Conditions | 2 |
| Paths | 2 |
| Total Lines | 12 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 50 | 11 | private function getFullTaxNumber(): string |
|
| 51 | { |
||
| 52 | 11 | $prefixStartsWithCountry = Str::of($this->getPrefix()) |
|
| 53 | 11 | ->startsWith($this->country); |
|
| 54 | |||
| 55 | 11 | if ($prefixStartsWithCountry) { |
|
| 56 | 4 | return (string) Str::of($this->tax_number) |
|
| 57 | 4 | ->substr(2) |
|
| 58 | 4 | ->start($this->country); |
|
| 59 | } |
||
| 60 | |||
| 61 | 7 | return Str::start($this->tax_number, $this->country); |
|
| 62 | } |
||
| 64 |