Skip to content

Commit

Permalink
Fixed infinite loop issue with low custom tickIntervals
Browse files Browse the repository at this point in the history
  • Loading branch information
highslide-software committed Nov 25, 2010
1 parent d9c7cb2 commit bd49a97
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions js/highcharts.src.js
Expand Up @@ -3929,8 +3929,12 @@ function Chart (options, callback) {
* @param {Number} num
*/
function correctFloat(num) {
var invMag = (magnitude < 1 ? mathRound(1 / magnitude) : 1) * 10;
return mathRound(num * invMag) / invMag;
var invMag, ret = num;
if (defined(magnitude)) {
invMag = (magnitude < 1 ? mathRound(1 / magnitude) : 1) * 10;
ret = mathRound(num * invMag) / invMag;
}
return num;
}

/**
Expand Down

0 comments on commit bd49a97

Please sign in to comment.