We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
| Conditions | 2 |
| Paths | 2 |
| Total Lines | 17 |
| Code Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 6 |
| Changes | 0 | ||
| 1 | <?php |
||
| 62 | public function bankAccount($countryCode, $bank) |
||
| 63 | { |
||
| 64 | $filteredCountryCode = strtoupper($countryCode); |
||
| 65 | switch ($filteredCountryCode) { |
||
| 66 | case 'DE': |
||
| 67 | return new GermanBankAccount($bank); |
||
| 68 | |||
| 69 | default: |
||
| 70 | throw new ComponentException( |
||
| 71 | sprintf( |
||
| 72 | 'Cannot provide bank account validation for country "%s" and bank "%s"', |
||
| 73 | $countryCode, |
||
| 74 | $bank |
||
| 75 | ) |
||
| 76 | ); |
||
| 77 | } |
||
| 78 | } |
||
| 79 | } |
||
| 80 |