X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/5be0f828c1cdf9f69aefdcc158fc06f2f5a67cfc..65a1ef1ad120c90b658e034efd54fa173e146671:/lib/Geocode.php diff --git a/lib/Geocode.php b/lib/Geocode.php index a9fa44fe..38f76142 100644 --- a/lib/Geocode.php +++ b/lib/Geocode.php @@ -148,15 +148,9 @@ $this->bBoundedSearch = (bool)$bBoundedSearch; } - function setViewBox($sLeft, $sBottom, $sRight, $sTop) + function setViewBox($fLeft, $fBottom, $fRight, $fTop) { - $fLeft = (float)$sLeft; - $fRight = (float)$sRight; - $fTop = (float)$sTop; - $fBottom = (float)$sBottom; - if ($fRight > $fLeft && $fBottom > $fTop - && ($fRight - $fLeft) < 2 && ($fBottom - $fTop) < 2) - $this->aViewBox = array($fLeft, $fBottom, $fRight, $fTop); + $this->aViewBox = array($fLeft, $fBottom, $fRight, $fTop); } function getViewBoxString() @@ -1705,7 +1699,7 @@ $aPointPolygon['minlon'] = $aPointPolygon['minlon'] - $fRadius; $aPointPolygon['maxlon'] = $aPointPolygon['maxlon'] + $fRadius; } - $aResult['aBoundingBox'] = array($aPointPolygon['minlat'],$aPointPolygon['maxlat'],$aPointPolygon['minlon'],$aPointPolygon['maxlon']); + $aResult['aBoundingBox'] = array((string)$aPointPolygon['minlat'],(string)$aPointPolygon['maxlat'],(string)$aPointPolygon['minlon'],(string)$aPointPolygon['maxlon']); } }