diff options
author | Andrew Harvey <andrew@alantgeo.com.au> | 2021-07-03 22:02:06 +1000 |
---|---|---|
committer | Andrew Harvey <andrew@alantgeo.com.au> | 2021-07-03 22:02:06 +1000 |
commit | 7f59a0a9a9a8d3a739a08bbb0336fbf9aaf8b85d (patch) | |
tree | df8b908366eec08ab2483f7b88257e228bcd3161 /bin | |
parent | 9202dc764411778bdbfe796e18390e8c4b4bd01e (diff) |
remove tracing properties from final import candidates
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/candidates.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/candidates.js b/bin/candidates.js index 6e2e7b0..95a3ceb 100755 --- a/bin/candidates.js +++ b/bin/candidates.js @@ -59,7 +59,7 @@ const suburbName = { } // suburb point in polygon index -let suburbLookup +let lookupSuburbs const outsideVicSuburb = { type: 'Feature', @@ -111,6 +111,9 @@ const candidates = new Transform({ process.stdout.write(` ${sourceCount.toLocaleString()}\r`) } + // remove tracing properties + delete feature.properties._pfi + // find which suburb this address is in const results = lookupSuburbs.search(...feature.geometry.coordinates.slice(0, 2), 1) const suburb = results ? (results.type === 'FeatureCollection' ? (results.features ? results.features[0] : outsideVicSuburb) : results[0]) : outsideVicSuburb |