]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge remote-tracking branch 'upstream/master'
authorSarah Hoffmann <lonvia@denofr.de>
Tue, 4 Oct 2016 18:34:34 +0000 (20:34 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Tue, 4 Oct 2016 18:34:34 +0000 (20:34 +0200)
docs/Import_and_update.md
lib/Geocode.php
sql/functions.sql
tests/features/api/regression.feature

index 2211d1405053a3f96f777c6ae1ac14f2d4c625a0..15aec256b9073715e3c933f3b7173c3b308ad5b0 100644 (file)
@@ -178,5 +178,5 @@ The following command will keep your database constantly up to date:
 
 If you have imported multiple country extracts and want to keep them
 up-to-date, have a look at the script in
-(issue #60)[https://github.com/twain47/Nominatim/issues/60].
+[issue #60](https://github.com/twain47/Nominatim/issues/60).
 
index 54e738ff5aa90e7ece10478c3f5588a7c55509b9..4ed90dc2bb89c2696168c617ff5a604e80bd75c7 100644 (file)
@@ -252,7 +252,7 @@ class Geocode
                     $aCountries[] = strtolower($sCountryCode);
                 }
             }
-            if (isset($aCountryCodes))
+            if (isset($aCountries))
                 $this->aCountryCodes = $aCountries;
         }
 
index 609d46c92c639567d58d8d1c7ee21678b110da60..b086786aa7a3544e2b1ff2f0f0ea73dffb8bdb58 100644 (file)
@@ -2343,7 +2343,7 @@ BEGIN
 
   IF for_place_id IS NULL THEN
     select parent_place_id, calculated_country_code, housenumber, rank_search, postcode, name, class, type from placex 
-      WHERE place_id = in_place_id and rank_address = 30 
+      WHERE place_id = in_place_id and  rank_search > 27
       INTO for_place_id, searchcountrycode, searchhousenumber, searchrankaddress, searchpostcode, searchhousename, searchclass, searchtype;
   END IF;
 
index ba8cca9b1c1a3f94b142bd6727d4785ba8b092b3..5b7f10ada79026e269e9541497e203b0d510013e 100644 (file)
@@ -207,3 +207,11 @@ Feature: API regression tests
          | osm_type   | osm_id     | latlon
          | node       | 257363453  | 35.8404121,128.5586643 +-100m
 
+    Scenario: trac #5427
+        Given the request parameters
+         | countrycodes |
+         | DE           |
+        When sending json search query "12345" with address
+        Then result addresses contain
+         | country_code |
+         | de           |