X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/f9889f81d6916f1419e3913f7e3e4d90e2f0816e..459ab3bbdcafec8707764896dcfeec5c3ed7454d:/lib-php/Geocode.php?ds=sidebyside diff --git a/lib-php/Geocode.php b/lib-php/Geocode.php index bf9a3262..acb79493 100644 --- a/lib-php/Geocode.php +++ b/lib-php/Geocode.php @@ -843,7 +843,9 @@ class Geocode $aResult['importance'] = 0.001; $aResult['foundorder'] = $aResult['addressimportance']; } else { - $aResult['importance'] = max(0.001, $aResult['importance']); + if ($aResult['importance'] == 0) { + $aResult['importance'] = 0.0001; + } $aResult['importance'] *= $this->viewboxImportanceFactor( $aResult['lon'], $aResult['lat']