Don't flag highways connected to amenity=parking_entrance nodes as disconnected

Don't flag oneways with entrance endpoints as impossible
This commit is contained in:
Quincy Morgan
2019-05-07 14:55:57 -04:00
parent 97cb90b562
commit 73467d53b4
2 changed files with 7 additions and 0 deletions

View File

@@ -122,6 +122,7 @@ export function validationDisconnectedWay() {
// entrances are considered connected
if (vertex.tags.entrance && vertex.tags.entrance !== 'no') return false;
if (vertex.tags.amenity === 'parking_entrance') return false;
return !parents.some(function(parentWay) {
if (parentWay === way) return false; // ignore the way we're testing

View File

@@ -65,6 +65,12 @@ export function validationImpossibleOneway() {
var node = context.hasEntity(nodeID);
if (wayType === 'highway') {
// entrances are considered connected
if (node.tags.entrance && node.tags.entrance !== 'no') return [];
if (node.tags.amenity === 'parking_entrance') return [];
}
// ignore if this node or its tile are unloaded
if (!node || !osm.isDataLoaded(node.loc)) return [];