Fix: HideMyAss: Cote d'Ivoire server country
This commit is contained in:
@@ -27,8 +27,13 @@ func parseOpenvpnURL(url, protocol string) (country, region, city string) {
|
||||
city = parts[2]
|
||||
}
|
||||
|
||||
return camelCaseToWords(country), camelCaseToWords(region),
|
||||
camelCaseToWords(city)
|
||||
country = camelCaseToWords(country)
|
||||
region = camelCaseToWords(region)
|
||||
city = camelCaseToWords(city)
|
||||
|
||||
country = mutateSpecialCountryCases(country)
|
||||
|
||||
return country, region, city
|
||||
}
|
||||
|
||||
func camelCaseToWords(camelCase string) (words string) {
|
||||
@@ -42,3 +47,12 @@ func camelCaseToWords(camelCase string) (words string) {
|
||||
}
|
||||
return words
|
||||
}
|
||||
|
||||
func mutateSpecialCountryCases(country string) string {
|
||||
switch country {
|
||||
case "Coted`Ivoire":
|
||||
return "Cote d'Ivoire"
|
||||
default:
|
||||
return country
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user