This commit is contained in:
@@ -45,7 +45,7 @@ public class GeoCountryService {
|
||||
}
|
||||
}
|
||||
|
||||
public Map<String, Integer> getUniqueGeoCount(List<String> ipList) {
|
||||
public Map<String, Integer> getUniqueGeoCount(List<String> ipList, String locale) {
|
||||
Set<String> uniqueCountries = new HashSet<>();
|
||||
Set<String> uniqueCountryCodes = new HashSet<>();
|
||||
Set<String> uniqueCities = new HashSet<>();
|
||||
@@ -53,7 +53,7 @@ public class GeoCountryService {
|
||||
if (ipList != null) {
|
||||
for (String ip : ipList) {
|
||||
try {
|
||||
String country = getCountryByIp(ip);
|
||||
String country = getCountryByIp(ip, locale);
|
||||
if (!"UNKNOWN".equals(country)) {
|
||||
uniqueCountries.add(country);
|
||||
}
|
||||
@@ -63,7 +63,7 @@ public class GeoCountryService {
|
||||
uniqueCountryCodes.add(countryCode);
|
||||
}
|
||||
|
||||
String city = getCityByIp(ip);
|
||||
String city = getCityByIp(ip, locale);
|
||||
if (!"UNKNOWN".equals(city)) {
|
||||
uniqueCities.add(city);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user