Skip to content

Commit

Permalink
fix: Fix error when a preset has no fields defined
Browse files Browse the repository at this point in the history
  • Loading branch information
gmaclennan committed Jul 12, 2022
1 parent 21287c1 commit 5819d87
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/renderer/components/MapFilter/MapFilter.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ function usePresets () {
.filter(p => p.geometry.includes('point'))
const usedFields = new Set()
for (const preset of presets) {
if (!Array.isArray(preset.fields)) continue
for (const fieldId of preset.fields) {
usedFields.add(fieldId)
}
Expand Down

0 comments on commit 5819d87

Please sign in to comment.