=== modified file 'dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/scripts/mapfish/core/GeoStat.js' --- dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/scripts/mapfish/core/GeoStat.js 2012-12-07 17:27:30 +0000 +++ dhis-2/dhis-web/dhis-web-apps/src/main/webapp/dhis-web-mapping/scripts/mapfish/core/GeoStat.js 2014-10-29 17:31:44 +0000 @@ -209,6 +209,10 @@ for (i = 1; i < nbBins; i++) { bounds[i] = values[binLastValPos]; binLastValPos += binSize; + + if (binLastValPos > values.length - 1) { + binLastValPos = values.length - 1; + } } bounds.push(values[values.length - 1]); }