From 19e262643d6312f25ffcf76c9381ed500d7a3b27 Mon Sep 17 00:00:00 2001 From: Quincy Morgan Date: Mon, 11 Feb 2019 13:38:37 -0500 Subject: [PATCH] Fix issue where "other" ways were not sorted into the "other" category for hiding purposes --- modules/renderer/features.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/renderer/features.js b/modules/renderer/features.js index 664647bd7..4929df610 100644 --- a/modules/renderer/features.js +++ b/modules/renderer/features.js @@ -359,12 +359,11 @@ export function rendererFeatures(context) { // 1. is a way that hasn't matched other 'interesting' feature rules, if (entity.type === 'way') { var parents = features.getParents(entity, resolver, geometry); - if (parents.length === 0) continue; // 2a. belongs only to a single multipolygon relation if ((parents.length === 1 && parents[0].isMultipolygon()) || // 2b. or belongs only to boundary relations - parents.every(function(parent) { return parent.tags.type === 'boundary'; })) { + (parents.length > 0 && parents.every(function(parent) { return parent.tags.type === 'boundary'; }))) { // ...then match whatever feature rules the parent relation has matched. // see #2548, #2887