]> git.openstreetmap.org Git - nominatim.git/commitdiff
remove lat/lon check for search terms
authorSarah Hoffmann <lonvia@denofr.de>
Thu, 6 Jul 2017 21:11:17 +0000 (23:11 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Sat, 19 Aug 2017 17:37:06 +0000 (19:37 +0200)
Was only used with GB postcodes which were removed.

lib/Geocode.php

index a133d8687ab0a78e24baeaa9fdb4d21ddf027fba..6f26b3cd73c13582f6341b44cbd0a29786abcc2b 100644 (file)
@@ -742,15 +742,6 @@ class Geocode
                                         }
                                         if ($aSearch['iSearchRank'] < $this->iMaxRank) $aNewWordsetSearches[] = $aSearch;
                                     }
-                                } elseif (isset($aSearchTerm['lat']) && $aSearchTerm['lat'] !== '' && $aSearchTerm['lat'] !== null) {
-                                    if ($aSearch['oNear'] === false) {
-                                        $aSearch['oNear'] = new NearPoint(
-                                            $aSearchTerm['lat'],
-                                            $aSearchTerm['lon'],
-                                            $aSearchTerm['radius']
-                                        );
-                                        if ($aSearch['iSearchRank'] < $this->iMaxRank) $aNewWordsetSearches[] = $aSearch;
-                                    }
                                 } elseif ($sPhraseType == 'postalcode' || ($aSearchTerm['class'] == 'place' && $aSearchTerm['type'] == 'postcode')) {
                                     // We need to try the case where the postal code is the primary element (i.e. no way to tell if it is (postalcode, city) OR (city, postalcode) so try both
                                     if (isset($aSearchTerm['word_id']) && $aSearchTerm['word_id'] && strpos($sNormQuery, $this->normTerm($aSearchTerm['word'])) !== false) {