]> git.openstreetmap.org Git - nominatim.git/commitdiff
Always ignore continents for addresses
authorSarah Hoffmann <lonvia@denofr.de>
Sun, 18 Nov 2018 16:00:12 +0000 (17:00 +0100)
committerSarah Hoffmann <lonvia@denofr.de>
Sun, 18 Nov 2018 16:00:59 +0000 (17:00 +0100)
Fixes #1236.

sql/functions.sql

index b07fe6883703cfd469b38b3adfac6a284ccdff8a..4a12921076e18a145f76dee652dd3349adebc4cd 100644 (file)
@@ -869,15 +869,7 @@ BEGIN
         END IF;
 
     ELSEIF NEW.class = 'place' THEN
-      IF NEW.type in ('continent') THEN
-        NEW.rank_search := 2;
-        IF ST_GeometryType(NEW.geometry) IN ('ST_Polygon','ST_MultiPolygon') THEN
-            NEW.rank_address := NEW.rank_search;
-        ELSE
-            NEW.rank_address := 0;
-        END IF;
-        NEW.country_code := NULL;
-      ELSEIF NEW.type in ('sea') THEN
+      IF NEW.type in ('continent', 'sea') THEN
         NEW.rank_search := 2;
         NEW.rank_address := 0;
         NEW.country_code := NULL;