mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-02-16 15:47:58 +00:00
penalize postcode searches with multiple name qualifiers
This commit is contained in:
@@ -271,6 +271,7 @@ class _TokenSequence:
|
||||
penalty = self.penalty
|
||||
else:
|
||||
penalty = self.penalty + 0.1
|
||||
penalty += 0.1 * max(0, len(base.address) - 1)
|
||||
yield dataclasses.replace(base, penalty=penalty)
|
||||
|
||||
def _get_assignments_address_forward(self, base: TokenAssignment,
|
||||
|
||||
Reference in New Issue
Block a user