mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-03-12 05:44:06 +00:00
reverse: choose interpolation only when further than point
The ST_DWithin check also includes objects that are the same distance. Another attempt at #545.
This commit is contained in:
@@ -153,7 +153,7 @@ class ReverseGeocode
|
|||||||
// look for an interpolation that is closer
|
// look for an interpolation that is closer
|
||||||
$aPlaceLine = $this->lookupInterpolation($sPointSQL, $fDistancePlacex);
|
$aPlaceLine = $this->lookupInterpolation($sPointSQL, $fDistancePlacex);
|
||||||
|
|
||||||
if ($aPlaceLine) {
|
if ($aPlaceLine && (float) $aPlaceLine['distance'] < (float) $fDistancePlacex) {
|
||||||
// interpolation is closer to point than placex house
|
// interpolation is closer to point than placex house
|
||||||
$bPlaceIsLine = true;
|
$bPlaceIsLine = true;
|
||||||
$aPlace = $aPlaceLine;
|
$aPlace = $aPlaceLine;
|
||||||
|
|||||||
Reference in New Issue
Block a user