Skip to content

Commit

Permalink
Merge pull request #138 from PaintServer/master
Browse files Browse the repository at this point in the history
Bail upon non-existent node element
  • Loading branch information
NeXTs committed Feb 1, 2018
2 parents 617159b + 79dff9d commit 3d08a48
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions clusterize.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@
opts.cluster_height = 0;
if( ! rows.length) return;
var nodes = this.content_elem.children;
if( ! nodes.length) return;
var node = nodes[Math.floor(nodes.length / 2)];
opts.item_height = node.offsetHeight;
// consider table's border-spacing
Expand Down

0 comments on commit 3d08a48

Please sign in to comment.