File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ class TableBody extends Component {
52
52
expandColSpan += 1 ;
53
53
}
54
54
55
- const tableRows = this . props . data . map ( function ( data , r ) {
55
+ let tableRows = this . props . data . map ( function ( data , r ) {
56
56
const tableColumns = this . props . columns . map ( function ( column , i ) {
57
57
const fieldValue = data [ column . name ] ;
58
58
const isFocusCell = r === y && i === x ;
@@ -188,10 +188,8 @@ class TableBody extends Component {
188
188
return ( result ) ;
189
189
} , this ) ;
190
190
191
- let tableRowsOutput = tableRows ;
192
-
193
191
if ( tableRows . length === 0 && ! this . props . withoutNoDataText ) {
194
- tableRowsOutput = [
192
+ tableRows = [
195
193
< TableRow key = '##table-empty##' >
196
194
< td data-toggle = 'collapse'
197
195
colSpan = { this . props . columns . length + ( isSelectRowDefined ? 1 : 0 ) }
@@ -209,7 +207,7 @@ class TableBody extends Component {
209
207
< table className = { tableClasses } >
210
208
{ React . cloneElement ( tableHeader , { ref : 'header' } ) }
211
209
< tbody ref = 'tbody' >
212
- { tableRowsOutput }
210
+ { tableRows }
213
211
</ tbody >
214
212
</ table >
215
213
</ div >
You can’t perform that action at this time.
0 commit comments