Skip to content

Commit

Permalink
Cache labels.length
Browse files Browse the repository at this point in the history
  • Loading branch information
ckyycc committed Dec 28, 2018
1 parent 01a4c25 commit 5e725e0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/scales/scale.time.js
Expand Up @@ -554,7 +554,7 @@ module.exports = function() {
datasets[i][j] = timestamp;
}
} else {
for (j = 0; j < labels.length; ++j) {
for (j = 0, jlen = labels.length; j < jlen; ++j) {
timestamps.push(labels[j]);
}
datasets[i] = labels.slice(0);
Expand Down

0 comments on commit 5e725e0

Please sign in to comment.