FuzzyLocationDescriptor country Code problem

Hi,

I try to set country code in location descriptor but it does not seem to work. What am i doing wrong?

Set countries = new HashSet<>();
countries.add(“GB”);
FuzzyLocationDescriptor fuzzyLocationDescriptor = new FuzzyLocationDescriptor.Builder()
.countryCodes(countries)
.build();

It looks like this is a bug.

As a workaround (not perfect) I’d suggest to get a viewport of chosen country and use it as a bounding box for search.

How critical is this issue for your case?

1 Like

Not very critical but wouldn’t want people to search for a town and get 10 of them from USA. I’ll try the viewport option.