Skip to content

Commit

Permalink
When not using Crossfilter and coordinate grids, the xDomain length m…
Browse files Browse the repository at this point in the history
…ay change. Need to trigger an update to xScale
  • Loading branch information
mtraynham committed Mar 23, 2015
1 parent 80fafeb commit 42b480e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/coordinate-grid-mixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,8 @@ dc.coordinateGridMixin = function (_chart) {

// has the domain changed?
var xdom = _x.domain();
if (!_lastXDomain || xdom.some(function (elem, i) { return elem !== _lastXDomain[i]; })) {
if (!_lastXDomain || _lastXDomain.length !== xdom.length ||
xdom.some(function (elem, i) { return elem !== _lastXDomain[i]; })) {
_chart.rescale();
}
_lastXDomain = xdom;
Expand Down

0 comments on commit 42b480e

Please sign in to comment.