fix(Map): rm moveend listener from setMaxBounds (#6958)
Calling `map.setMapBounds`, adds the `"moveend"` event listener
`_panInsideMaxBounds`. Previously, this did not get cleaned up via
`remove`.
Simon Legner authored 4 years ago
Vladimir Agafonkin committed 4 years ago
71 | 71 | |
72 | 72 | it("does not throw if removed during animation", function () { |
73 | 73 | var container = document.createElement('div'), |
74 | map = new L.Map(container).setView([0, 0], 1); | |
74 | map = new L.Map(container).setView([0, 0], 1).setMaxBounds([[0, 1], [2, 3]]); | |
75 | 75 | |
76 | 76 | // Force creation of animation proxy, |
77 | 77 | // otherwise browser checks disable it |