X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/033b9590bdf562a21a45b85e9cfaefee0db754e1..10c5d7f6f6f6ea321fea870e1ec984fa5e4af135:/lib/Geocode.php diff --git a/lib/Geocode.php b/lib/Geocode.php index aa65cb69..876a40b5 100644 --- a/lib/Geocode.php +++ b/lib/Geocode.php @@ -514,7 +514,7 @@ $sSQL .= " order by importance desc"; if (CONST_Debug) { echo "
"; var_dump($sSQL); } - $aSearchResults = chksql($this->oDB->getAll($sSQL); + $aSearchResults = chksql($this->oDB->getAll($sSQL), "Could not get details for place."); return $aSearchResults; @@ -879,7 +879,7 @@ $sViewboxCentreSQL .= ")'::geometry,4326)"; $sSQL = "select st_buffer(".$sViewboxCentreSQL.",".(float)($_GET['routewidth']/69).")"; - $this->sViewboxSmallSQL = chksql($this->oDB->getOne($sSQL); + $this->sViewboxSmallSQL = chksql($this->oDB->getOne($sSQL), "Could not get small viewbox."); $this->sViewboxSmallSQL = "'".$this->sViewboxSmallSQL."'::geometry"; @@ -1414,9 +1414,8 @@ $sSQL .= " limit ".$this->iLimit; if (CONST_Debug) { var_dump($sSQL); } - $aViewBoxPlaceIDs = chksql($this->oDB->getAll($sSQL)); + $aViewBoxPlaceIDs = chksql($this->oDB->getAll($sSQL), "Could not get places for search terms."); - } //var_dump($aViewBoxPlaceIDs); // Did we have an viewbox matches? $aPlaceIDs = array(); @@ -1638,11 +1637,6 @@ } - if (PEAR::IsError($aPlaceIDs)) - { - failInternalError("Could not get place IDs from tokens." ,$sSQL, $aPlaceIDs); - } - if (CONST_Debug) { echo "
Place IDs: "; var_Dump($aPlaceIDs); } foreach($aPlaceIDs as $iPlaceID)