Closed crh3675 closed 5 years ago
We recently noticed when using a NOAA WMS feed, that our page would hang. The underlying cause was that NOAA had names such as <Name>0</Name> and <Name>1</Name> for their layers. It seems the code here:
<Name>0</Name>
<Name>1</Name>
layers.forEach(function(current) { if (current.querySelector("Name").innerHTML === layerName) { layer = current; } })
becomes the issue due to strict type checking and should be updated as such:
layers.forEach(function(current) { if (current.querySelector("Name").innerHTML === String(layerName)) { layer = current; } })
We recently noticed when using a NOAA WMS feed, that our page would hang. The underlying cause was that NOAA had names such as
<Name>0</Name>
and<Name>1</Name>
for their layers. It seems the code here:becomes the issue due to strict type checking and should be updated as such: