]> git.openstreetmap.org Git - nominatim.git/commitdiff
penalize housenumber after the postcode
authorSarah Hoffmann <lonvia@denofr.de>
Tue, 24 Oct 2017 21:30:41 +0000 (23:30 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Tue, 24 Oct 2017 21:30:41 +0000 (23:30 +0200)
lib/SearchDescription.php

index e949585208feef8062e5aa1924518dfbee1b49cf..702e7dea2c583d0aabfde10484ee454ca3458d2d 100644 (file)
@@ -247,7 +247,10 @@ class SearchDescription
                     $oSearch->iSearchRank++;
                 }
                 // also must not appear in the middle of the address
-                if (sizeof($this->aAddress) || sizeof($this->aAddressNonSearch)) {
+                if (sizeof($this->aAddress)
+                    || sizeof($this->aAddressNonSearch)
+                    || $this->sPostcode
+                ) {
                     $oSearch->iSearchRank++;
                 }
                 $aNewSearches[] = $oSearch;