Skip to content

Commit 70827ee

Browse files
committed
fix #1061
1 parent 43b5eeb commit 70827ee

File tree

1 file changed

+7
-0
lines changed
  • packages/react-bootstrap-table2/src/contexts

1 file changed

+7
-0
lines changed

packages/react-bootstrap-table2/src/contexts/index.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,13 @@ const withContext = Base =>
9191
this.PaginationContext = nextProps.pagination.createContext(
9292
this.isRemotePagination, this.handleRemotePageChange);
9393
}
94+
if (!nextProps.cellEdit && this.props.cellEdit) {
95+
this.CellEditContext = null;
96+
}
97+
if (nextProps.cellEdit && !this.props.cellEdit) {
98+
this.CellEditContext = nextProps.cellEdit.createContext(
99+
_, dataOperator, this.isRemoteCellEdit, this.handleRemoteCellChange);
100+
}
94101
}
95102

96103
renderBase() {

0 commit comments

Comments
 (0)