Skip to content

Commit

Permalink
Merge pull request #1 from cedrouck/cedrouck-patch-1
Browse files Browse the repository at this point in the history
Fix: Cannot read property 'type' of undefined
  • Loading branch information
cedrouck authored Oct 10, 2017
2 parents a04886c + 048003f commit 9049073
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/BootstrapTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class BootstrapTable extends Component {
const nextDataFields = React.Children.map(props.children, column => column.props.dataField);
React.Children.forEach(this.props.children, column => {
const { dataField, filter } = column.props;
if (!nextDataFields.includes(dataField)) {
if (filter && !nextDataFields.includes(dataField)) {
// Clear filter
this.filter.handleFilter(dataField, '', filter.type, filter);
}
Expand Down

0 comments on commit 9049073

Please sign in to comment.