diff --git a/src/MarkerCluster.js b/src/MarkerCluster.js index fe5fad396..9744ec360 100644 --- a/src/MarkerCluster.js +++ b/src/MarkerCluster.js @@ -185,7 +185,7 @@ L.MarkerCluster = L.Marker.extend({ }, _recursivelyAddChildrenToMap: function (startPos, zoomLevel, bounds) { - this._recursively(bounds, 0, zoomLevel, + this._recursively(bounds, -1, zoomLevel, function (c) { if (zoomLevel === c._zoom) { return; diff --git a/src/MarkerClusterGroup.js b/src/MarkerClusterGroup.js index e7fea2796..d0f94f567 100644 --- a/src/MarkerClusterGroup.js +++ b/src/MarkerClusterGroup.js @@ -476,6 +476,9 @@ L.MarkerClusterGroup = L.FeatureGroup.extend({ gridUnclustered[zoom].addObject(layer, markerPoint); } + //Didn't get in anything, add us to the top + this._topClusterLevel._addChild(layer); + layer.__parent = this._topClusterLevel; return; },