X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/d35eb4105e48c09996dca7c01c1366d6d2da12ab..103800a732759d044bcc767d70a1ef943db53f09:/nominatim/api/search/geocoder.py diff --git a/nominatim/api/search/geocoder.py b/nominatim/api/search/geocoder.py index 6b58c945..27e4d91e 100644 --- a/nominatim/api/search/geocoder.py +++ b/nominatim/api/search/geocoder.py @@ -141,7 +141,8 @@ class ForwardGeocoder: or (result.importance is not None and result.importance < 0): continue distance = 0.0 - norm = self.query_analyzer.normalize_text(result.display_name) + norm = self.query_analyzer.normalize_text(' '.join((result.display_name, + result.country_code or ''))) words = set((w for w in norm.split(' ') if w)) if not words: continue