From 8f7a60001f375aa792320030fb65e0d7c9687996 Mon Sep 17 00:00:00 2001 From: Andrew Harvey Date: Fri, 7 May 2021 22:50:57 +1000 Subject: fix reduceOverlap to push feature not unit number --- bin/reduceOverlap.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bin') diff --git a/bin/reduceOverlap.js b/bin/reduceOverlap.js index aa18125..bc3dbd0 100755 --- a/bin/reduceOverlap.js +++ b/bin/reduceOverlap.js @@ -129,7 +129,7 @@ const reduce = new Transform({ debugStreams.oneUnitOneNonUnit.write(feature) }) } - this.push(allOtherUnits[0]) + this.push(featureGroup.filter(f => 'addr:unit' in f.properties)[0]) } else { nonUnitFeature.properties['addr:flats'] = unitsToRanges(allOtherUnits) // TODO should we set addr:flats:prefix from addr:unit:prefix? -- cgit v1.2.3