Skip to content

Commit

Permalink
Merge pull request #2481 from SuperZDev/master
Browse files Browse the repository at this point in the history
fixed:the params's type may be [Number] like '25'
  • Loading branch information
pissang committed Jan 23, 2016
2 parents a39afcb + e408795 commit 4e71f6c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/scale/Interval.js
Expand Up @@ -23,11 +23,12 @@ define(function (require) {

setExtent: function (start, end) {
var thisExtent = this._extent;
//start,end may be a Number like '25',so...
if (!isNaN(start)) {
thisExtent[0] = start;
thisExtent[0] = parseFloat(start);
}
if (!isNaN(end)) {
thisExtent[1] = end;
thisExtent[1] = parseFloat(end);
}
},

Expand Down Expand Up @@ -203,4 +204,4 @@ define(function (require) {
};

return IntervalScale;
});
});

0 comments on commit 4e71f6c

Please sign in to comment.