diff --git a/nominatim/api/search/geocoder.py b/nominatim/api/search/geocoder.py index 6b58c9457..27e4d91ea 100644 --- a/nominatim/api/search/geocoder.py +++ b/nominatim/api/search/geocoder.py @@ -141,7 +141,8 @@ def rerank_by_query(self, query: QueryStruct, results: SearchResults) -> None: 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