Skip to content

Commit 3cb308d

Browse files
benmccannetimberg
authored andcommitted
Fix sampleSize option (#6586)
1 parent c6c991d commit 3cb308d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/core/core.scale.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@ var Scale = Element.extend({
448448

449449
// Compute tick rotation and fit using a sampled subset of labels
450450
// We generally don't need to compute the size of every single label for determining scale size
451-
samplingEnabled = sampleSize > ticks.length;
451+
samplingEnabled = sampleSize < ticks.length;
452452
labels = me._convertTicksToLabels(samplingEnabled ? sample(ticks, sampleSize) : ticks);
453453

454454
// _configure is called twice, once here, once from core.controller.updateLayout.

0 commit comments

Comments
 (0)