diff --git a/src/c3nav/editor/static/editor/js/editor.js b/src/c3nav/editor/static/editor/js/editor.js index 3902f287..6e680dfb 100644 --- a/src/c3nav/editor/static/editor/js/editor.js +++ b/src/c3nav/editor/static/editor/js/editor.js @@ -462,7 +462,7 @@ editor = { _click_editing_layer: function(e) { // click callback for a currently edited layer. create a hole on ctrl+click. if ((e.originalEvent.ctrlKey || e.originalEvent.metaKey)) { - if (e.target.feature.geometry.type == 'Polygon') { + if (e.target instanceof L.Polygon) { this.editor.newHole(e.latlng); } }