diff --git a/js/id/presets/preset.js b/js/id/presets/preset.js index af8ac6182..3d4d063e0 100644 --- a/js/id/presets/preset.js +++ b/js/id/presets/preset.js @@ -1,12 +1,12 @@ iD.presets.Preset = function(preset, forms) { - preset.form = preset.form.map(function(f) { + preset.form = preset.form ? preset.form.map(function(f) { if (typeof f === 'string') { return forms[f]; } else { return f; } - }); + }) : []; preset.matchType = function(entity, resolver) { return preset.match.type.indexOf(entity.geometry(resolver)) >= 0; diff --git a/presets/presets.json b/presets/presets.json index 5f765ccc2..dcf0d475c 100644 --- a/presets/presets.json +++ b/presets/presets.json @@ -18,8 +18,7 @@ "leisure": "park" } }, - "icon": "park", - "form": [] + "icon": "park" }, { "name": "water", @@ -29,8 +28,7 @@ "natural": "water" } }, - "icon": "", - "form": [] + "icon": "" }, { "name": "wetland", @@ -40,8 +38,7 @@ "natural": "wetland" } }, - "icon": "", - "form": [] + "icon": "" }, { "name": "wood", @@ -51,8 +48,7 @@ "natural": "wood" } }, - "icon": "", - "form": [] + "icon": "" }, { "name": "coastline", @@ -62,8 +58,7 @@ "natural": "coastline" } }, - "icon": "", - "form": [] + "icon": "" }, { "name": "supermarket", @@ -249,8 +244,7 @@ "waterway": "river" } }, - "icon": "waterway-river", - "form": [] + "icon": "waterway-river" }, { "name": "stream", @@ -337,8 +331,7 @@ "railway": "rail" } }, - "icon": "railway-rail", - "form": [] + "icon": "railway-rail" }, { "name": "subway", @@ -348,8 +341,7 @@ "railway": "subway" } }, - "icon": "railway-rail", - "form": [] + "icon": "railway-rail" }, { "name": "trunk highway", @@ -370,8 +362,7 @@ "highway": "footway" } }, - "icon": "highway-footway", - "form": [] + "icon": "highway-footway" }, { "name": "cycle path", @@ -460,7 +451,6 @@ "highway": "turning_circle" } }, - "icon": "circle", - "form": [] + "icon": "circle" } ]