[OpenLayers-Users] ol2.13 and old ticket 3621 calculateResolutions
Steve.Toutant at inspq.qc.ca
Steve.Toutant at inspq.qc.ca
Fri Jun 7 12:45:30 PDT 2013
Hi,
We have a problem with OL2.13 in Google Chrome only.
Here is the error message: Uncaught RangeError: Invalid array length
Layer.js line 1050
It seems to be related to this issue
http://trac.osgeo.org/openlayers/ticket/3621
it fails because numZoomLevels is NaN
But this code at line 1042 should manage that....
// are we able to calculate resolutions?
if(typeof numZoomLevels !== "number" || numZoomLevels <= 0 ||
(typeof maxResolution !== "number" && typeof minResolution !==
"number")) {
return;
}
I fix it adding isNaN(numZoomLevels)
// are we able to calculate resolutions?
if(isNaN(numZoomLevels) || typeof numZoomLevels !== "number" ||
numZoomLevels <= 0 ||
(typeof maxResolution !== "number" &&
typeof minResolution !== "number")) {
return;
}
I went on github but could not find the issue.
So I submit here
Steve
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/openlayers-users/attachments/20130607/0b8903cb/attachment.html>
More information about the Users
mailing list