MapKit JS: Searching in a region not working properly

Hi guys,

I've created a search instance with MapKit JS, tried to look for all FoodMarkets in my region, passed the maps region (shown area) as argument but the search returns a lot of results not in my region, about 100km far away.

That's my code:

var search = new mapkit.Search({
    getUserLocation: false,
    region: Map.region,
  });

  search.search("Netto", function (error, data) {
    if (error) {
      // Handle search error
      console.log("MAP ERROR: " + error);
      return;
    }

    MapVisibleAnnotations = data.places.map(function (place) {
      var annotation = new mapkit.MarkerAnnotation(place.coordinate);
      annotation.title = place.name;
      annotation.subtitle = place.formattedAddress;
      annotation.color = "#9B6134";
      return annotation;
    });

    Map.showItems(MapVisibleAnnotations);
  });

What have I done wrong? It should only return all "netto" super markets in my region (about ~2km radius allowed)

That's the desired search region:

That's the result annotations, far far wider than it should be:

When I change the search query from "Netto" to "Netto Straubing" (Straubing is the city name) -> it returns all "Netto" supermarkets nearby which is fine. But why doesn't it affect to the given region?

Accepted Answer

Does anybody have an idea about this? :(

MapKit JS: Searching in a region not working properly
 
 
Q