Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clearLayers doesn't work if the group is removed from the map #79

Closed
duncanparkes opened this issue Oct 16, 2012 · 0 comments
Closed

clearLayers doesn't work if the group is removed from the map #79

duncanparkes opened this issue Oct 16, 2012 · 0 comments

Comments

@duncanparkes
Copy link
Contributor

If you remove a MarkerClusterGroup from the map and the call clearLayers on it, nothing gets removed. Looking in the code, it's clearly expecting that if _map doesn't exist, the clusterer will never have been added to a map.

duncanparkes pushed a commit to duncanparkes/Leaflet.markercluster that referenced this issue Oct 17, 2012
When a MarkerClusterGroup has been on a map, but isn't any longer,
we still need to clear out its markers.
danzel pushed a commit that referenced this issue Oct 18, 2012
When a MarkerClusterGroup has been on a map, but isn't any longer,
we still need to clear out its markers.
(cherry picked from commit 2a90a86)

Conflicts:

	dist/leaflet.markercluster.js
@danzel danzel closed this as completed Oct 18, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants