]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/PlaceLookup.php
PlaceLookup should return results in input order
[nominatim.git] / lib / PlaceLookup.php
index 8a1a366678652513e37378e15c36c64d18c0e679..0a285a6a78b69ab7b5b9f16c8493a7f1c22718bb 100644 (file)
@@ -448,16 +448,17 @@ class PlaceLookup
                 }
             }
 
-            $aPlace['addresstype'] = ClassTypes\getProperty(
+            $aPlace['addresstype'] = ClassTypes\getLabelTag(
                 $aPlace,
-                'simplelabel',
-                $aPlace['class']
+                $aPlace['country_code']
             );
+
+            $aResults[$aPlace['place_id']] = $aPlace;
         }
 
-        Debug::printVar('Places', $aPlaces);
+        Debug::printVar('Places', $aResults);
 
-        return $aPlaces;
+        return $aResults;
     }
 
     /* returns an array which will contain the keys