Conditions | 7 |
Paths | 5 |
Total Lines | 17 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 8 |
CRAP Score | 7.0671 |
Changes | 1 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
23 | 27 | public function getFileName($countryCallingCode, $language, $script, $region) |
|
|
|||
24 | { |
||
25 | 27 | if (strlen($language) == 0) { |
|
26 | return ""; |
||
27 | } |
||
28 | |||
29 | 27 | if ($language === 'zh' && ($region == 'TW' || $region == 'HK' || $region == 'MO')) { |
|
30 | 1 | $language = 'zh_Hant'; |
|
31 | 1 | } |
|
32 | |||
33 | 27 | if ($this->inMap($language, $countryCallingCode)) { |
|
34 | 22 | return $language . DIRECTORY_SEPARATOR . $countryCallingCode . '.php'; |
|
35 | } |
||
36 | |||
37 | |||
38 | 9 | return ""; |
|
39 | } |
||
40 | |||
47 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.