From 5237f44c4a3361e321bea6bcd2a7e3390a3cbb9c Mon Sep 17 00:00:00 2001 From: Sarah Hoffmann Date: Thu, 6 Jul 2017 23:11:17 +0200 Subject: [PATCH] remove lat/lon check for search terms Was only used with GB postcodes which were removed. --- lib/Geocode.php | 9 --------- 1 file changed, 9 deletions(-) diff --git a/lib/Geocode.php b/lib/Geocode.php index a133d868..6f26b3cd 100644 --- a/lib/Geocode.php +++ b/lib/Geocode.php @@ -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) { -- 2.45.2