]> git.openstreetmap.org Git - nominatim.git/commitdiff
use highest admin boundary for duplicated ones
authorSarah Hoffmann <lonvia@denofr.de>
Mon, 26 Oct 2020 20:11:06 +0000 (21:11 +0100)
committerSarah Hoffmann <lonvia@denofr.de>
Wed, 28 Oct 2020 09:49:26 +0000 (10:49 +0100)
lib/Geocode.php

index b07d1adebe587d12f01a738cdf8d39ad1ffd2ddd..69b6f41ca46e1085d2917592dc2757780bbbc64a 100644 (file)
@@ -934,6 +934,8 @@ class Geocode
                 } else {
                     $aResult['foundorder'] += 0.01;
                 }
+                // - rank
+                $aResult['foundorder'] -= 0.00001 * (30 - $aResult['rank_search']);
 
                 // Adjust importance for the number of exact string matches in the result
                 $iCountWords = 0;