Skip to content

Commit

Permalink
get rid of loop to handle linear scale min>=max
Browse files Browse the repository at this point in the history
  • Loading branch information
xg-wang committed May 15, 2017
1 parent deb58b3 commit 5d5e67f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/scales/scale.linearbase.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ module.exports = function(Chart) {
}
}

while (me.min >= me.max) {
me.max++;
if (me.min >= me.max) {
me.max = me.min + 1;

if (tickOpts.min === undefined && !tickOpts.beginAtZero) {
me.min--;
Expand Down

0 comments on commit 5d5e67f

Please sign in to comment.