Merge pull request #3489 from RLRR/fix-paninsidebounds-array-param

Make panInsideBounds method accept bounds in array form
This commit is contained in:
Vladimir Agafonkin 2015-05-25 15:25:11 +03:00
commit df84336388

View File

@ -175,7 +175,7 @@ L.Map = L.Evented.extend({
panInsideBounds: function (bounds, options) {
var center = this.getCenter(),
newCenter = this._limitCenter(center, this._zoom, bounds);
newCenter = this._limitCenter(center, this._zoom, L.latLngBounds(bounds));
if (center.equals(newCenter)) { return this; }