File tree 1 file changed +2
-4
lines changed
1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -119,10 +119,8 @@ class BootstrapTable extends React.Component {
119
119
if ( Array . isArray ( nextProps . data ) ) {
120
120
this . store . setData ( nextProps . data ) ;
121
121
let paginationDom = this . refs . pagination ;
122
- let page = nextProps . options . page ||
123
- ( paginationDom ? paginationDom . getCurrentPage ( ) : 1 ) ;
124
- let sizePerPage = nextProps . options . sizePerPage ||
125
- ( paginationDom ? paginationDom . getSizePerPage ( ) : Const . SIZE_PER_PAGE_LIST [ 0 ] ) ;
122
+ let page = paginationDom && paginationDom . getCurrentPage ( ) || nextProps . options . page || 1 ;
123
+ let sizePerPage = paginationDom && paginationDom . getSizePerPage ( ) || nextProps . options . sizePerPage || Const . SIZE_PER_PAGE_LIST [ 0 ] ;
126
124
// #125
127
125
if ( page > Math . ceil ( nextProps . data . length / sizePerPage ) ) page = 1 ;
128
126
let sortInfo = this . store . getSortInfo ( ) ;
You can’t perform that action at this time.
0 commit comments