From a5e03adb45e2f6c560740f874f9d909e88e82ec7 Mon Sep 17 00:00:00 2001 From: Per Liedman Date: Mon, 28 Aug 2017 10:40:47 +0200 Subject: [PATCH] Store return value from wrapLatLngBounds (#5715) Fixes #5536. --- src/layer/tile/GridLayer.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/layer/tile/GridLayer.js b/src/layer/tile/GridLayer.js index 15f12cc0..ee7c837e 100755 --- a/src/layer/tile/GridLayer.js +++ b/src/layer/tile/GridLayer.js @@ -745,7 +745,7 @@ export var GridLayer = Layer.extend({ bounds = new LatLngBounds(nw, se); if (!this.options.noWrap) { - map.wrapLatLngBounds(bounds); + bounds = map.wrapLatLngBounds(bounds); } return bounds;