From 7765baf03b2830e817d531a2b4041c11628d9bdf Mon Sep 17 00:00:00 2001 From: Quincy Morgan Date: Wed, 6 Feb 2019 13:12:58 -0500 Subject: [PATCH] Make merge threshold consistent for almost_junction and tag_suggests_area connection fixes --- modules/validations/almost_junction.js | 2 +- modules/validations/tag_suggests_area.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/validations/almost_junction.js b/modules/validations/almost_junction.js index 31a8755bc..16f23a362 100644 --- a/modules/validations/almost_junction.js +++ b/modules/validations/almost_junction.js @@ -146,7 +146,7 @@ export function validationAlmostJunction() { var edgeWayNodes = context.graph().childNodes(edgeWay); var closestNodeInfo = geoSphericalClosestNode(edgeWayNodes, crossLoc); // if there is already a point nearby, just connect to that - if (closestNodeInfo.distance < 0.8) { + if (closestNodeInfo.distance < 0.75) { context.perform( actionMergeNodes([closestNodeInfo.node.id, endNode.id], closestNodeInfo.node.loc), t('issues.fix.connect_almost_junction.undo_redo') diff --git a/modules/validations/tag_suggests_area.js b/modules/validations/tag_suggests_area.js index 4a2078a6e..84a6aaef2 100644 --- a/modules/validations/tag_suggests_area.js +++ b/modules/validations/tag_suggests_area.js @@ -39,7 +39,7 @@ export function validationTagSuggestsArea() { var firstToLastDistanceMeters = geoSphericalDistance(nodes[0].loc, nodes[nodes.length-1].loc); var connectEndpointsOnClick; // if the distance is very small, attempt to merge the endpoints - if (firstToLastDistanceMeters < 0.5) { + if (firstToLastDistanceMeters < 0.75) { testNodes = _clone(nodes); testNodes.pop(); testNodes.push(testNodes[0]);