X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/ce95c55d656a06272177d2c41410322bf3a14817..c2629bc08d081262a7fd1cbd9d52acb5f44bd8ec:/lib/lib.php diff --git a/lib/lib.php b/lib/lib.php index a5439ef2..8a49761b 100644 --- a/lib/lib.php +++ b/lib/lib.php @@ -545,8 +545,12 @@ function _debugDumpGroupedSearches($aData, $aTokens) echo "".$aRow['sPostcode'].""; echo "".$aRow['sHouseNumber'].""; - echo "".$aRow['oNear']->lat().""; - echo "".$aRow['oNear']->lon().""; + if ($aRow['oNear']) { + echo "".$aRow['oNear']->lat().""; + echo "".$aRow['oNear']->lon().""; + } else { + echo ""; + } echo "".$aRow['fRadius'].""; echo ""; @@ -613,10 +617,10 @@ function geometryText2Points($geometry_as_text, $fRadius) // preg_match_all('/(-?[0-9.]+) (-?[0-9.]+)/', $aMatch[1], $aPolyPoints, PREG_SET_ORDER); // - } elseif (preg_match('#MULTIPOLYGON\\(\\(\\(([- 0-9.,]+)#', $geometry_as_text, $aMatch)) { +/* } elseif (preg_match('#MULTIPOLYGON\\(\\(\\(([- 0-9.,]+)#', $geometry_as_text, $aMatch)) { // preg_match_all('/(-?[0-9.]+) (-?[0-9.]+)/', $aMatch[1], $aPolyPoints, PREG_SET_ORDER); - // + */ } elseif (preg_match('#POINT\\((-?[0-9.]+) (-?[0-9.]+)\\)#', $geometry_as_text, $aMatch)) { // $aPolyPoints = createPointsAroundCenter($aMatch[1], $aMatch[2], $fRadius);