| Conditions | 2 |
| Paths | 1 |
| Total Lines | 10 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 7 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php namespace Propaganistas\LaravelPhone\Traits; |
||
| 25 | 99 | protected function parseCountries($countries) |
|
| 26 | { |
||
| 27 | 99 | return Collection::make(is_array($countries) ? $countries : func_get_args()) |
|
| 28 | ->map(function ($country) { |
||
| 29 | 99 | return strtoupper($country); |
|
| 30 | 99 | }) |
|
| 31 | 99 | ->filter(function ($value) { |
|
| 32 | 99 | return static::isValidCountryCode($value); |
|
| 33 | 99 | })->toArray(); |
|
| 34 | } |
||
| 35 | } |