]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/Geocode.php
make sure place exists before printing hierarchy
[nominatim.git] / lib / Geocode.php
index dfb3af2ae823c60eabe816bcc3af2d6c7bb651f1..a7adb2b98a06fe1f3fd6d05ae053f4621dcbcb13 100644 (file)
                                foreach(explode(',',$aParams['exclude_place_ids']) as $iExcludedPlaceID)
                                {
                                        $iExcludedPlaceID = (int)$iExcludedPlaceID;
-                                       if ($iExcludedPlaceID) $aExcludePlaceIDs[$iExcludedPlaceID] = $iExcludedPlaceID;
+                                       if ($iExcludedPlaceID)
+                                               $aExcludePlaceIDs[$iExcludedPlaceID] = $iExcludedPlaceID;
                                }
-                               $this->aExcludePlaceIDs = $aExcludePlaceIDs;
+
+                               if (isset($aExcludePlaceIDs))
+                                       $this->aExcludePlaceIDs = $aExcludePlaceIDs;
                        }
 
                        // Only certain ranks of feature