From 451dc7b871289dd363e39925a60d3e31e4b8a150 Mon Sep 17 00:00:00 2001 From: Tsvetan Tsvetkov Date: Wed, 3 May 2017 09:52:53 +0300 Subject: [PATCH] Fixes issue #49 --- src/leaflet.groupedlayercontrol.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/leaflet.groupedlayercontrol.js b/src/leaflet.groupedlayercontrol.js index 95a3b35..ff73ea6 100644 --- a/src/leaflet.groupedlayercontrol.js +++ b/src/leaflet.groupedlayercontrol.js @@ -66,7 +66,7 @@ L.Control.GroupedLayers = L.Control.extend({ var id = L.Util.stamp(layer); var _layer = this._getLayer(id); if (_layer) { - delete this.layers[this.layers.indexOf(_layer)]; + delete this._layers[this._layers.indexOf(_layer)]; } this._update(); return this;