From 795fe29cddad90f324e8ffd509547bdb0a486719 Mon Sep 17 00:00:00 2001 From: Bryan Housel Date: Wed, 26 Apr 2017 00:34:48 -0400 Subject: [PATCH] Only show connected vertex if it connects an interesting line --- modules/osm/node.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/modules/osm/node.js b/modules/osm/node.js index a407750b2..d19d0366c 100644 --- a/modules/osm/node.js +++ b/modules/osm/node.js @@ -59,8 +59,13 @@ _.extend(osmNode.prototype, { return resolver.transient(this, 'isConnected', function() { var parents = resolver.parentWays(this); - // vertex is connected to multiple parent ways - if (parents.length > 1) { + function isLine(entity) { + return entity.geometry(resolver) === 'line' && + entity.hasInterestingTags(); + } + + // vertex is connected to multiple parent lines + if (parents.length > 1 && _.some(parents, isLine)) { return true; } else if (parents.length === 1) {