Skip to content

Commit

Permalink
Fixed #959 - DataTable fails to render if columns are mapped and has …
Browse files Browse the repository at this point in the history
…a static column
  • Loading branch information
mertsincan committed Jul 19, 2019
1 parent dcfbe91 commit 3a1afff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/datatable/DataTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -620,13 +620,13 @@ export class DataTable extends Component {
else {
if(this.props.children instanceof Array) {
for(let i = 0; i < this.props.children.length; i++) {
if(this.props.children[i].props.footer) {
if(this.props.children[i].props && this.props.children[i].props.footer) {
return true;
}
}
}
else {
return this.props.children.props.footer !== null;
return this.props.children.props && this.props.children.props.footer !== null;
}
}
}
Expand Down

0 comments on commit 3a1afff

Please sign in to comment.