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 | 10 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 6 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 22 | public function __construct($countryCode) |
||
| 23 | { |
||
| 24 | $shortName = ucfirst(mb_strtolower($countryCode)).'IdentityCard'; |
||
| 25 | $className = __NAMESPACE__.'\\Locale\\'.$shortName; |
||
| 26 | if (!class_exists($className)) { |
||
| 27 | throw new ComponentException(sprintf('There is no support for identity cards from "%s"', $countryCode)); |
||
| 28 | } |
||
| 29 | |||
| 30 | $this->countryCode = $countryCode; |
||
| 31 | $this->validatable = new $className(); |
||
| 32 | } |
||
| 34 |