Skip to content

Commit

Permalink
More fixes to 0 Int (print issues)
Browse files Browse the repository at this point in the history
  • Loading branch information
mkikets99 committed Feb 9, 2021
1 parent 8c1941b commit 871a747
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lib/index.js
Expand Up @@ -324,7 +324,7 @@ var ReactDatatable = function (_Component) {
var cellData = _server2.default.renderToStaticMarkup(_column.cell(record, i));
cellData = this.strip(cellData);
tableHtml += "<td>" + cellData + "</td>";
} else if (record[_column.key]) {
} else if (record[_column.key] !== undefined) {
tableHtml += "<td>" + record[_column.key] + "</td>";
} else {
tableHtml += "<td></td>";
Expand Down Expand Up @@ -480,7 +480,7 @@ var ReactDatatable = function (_Component) {
var cellData = _server2.default.renderToStaticMarkup(_column2.cell(record, i));
cellData = this.strip(cellData);
newRecord[_column2.key] = cellData;
} else if (record[_column2.key]) {
} else if (record[_column2.key] !== undefined) {
var colValue = record[_column2.key];
colValue = typeof colValue === "string" ? colValue.replace(/"/g, '""') : colValue;
newRecord[_column2.key] = '"' + colValue + '"';
Expand Down
4 changes: 2 additions & 2 deletions src/index.js
Expand Up @@ -229,7 +229,7 @@ class ReactDatatable extends Component {
let cellData = ReactDOMServer.renderToStaticMarkup(column.cell(record, i));
cellData = this.strip(cellData);
tableHtml += "<td>" + cellData + "</td>";
}else if (record[column.key]) {
}else if (record[column.key]!==undefined) {
tableHtml += "<td>" + record[column.key] + "</td>";
} else {
tableHtml += "<td></td>";
Expand Down Expand Up @@ -336,7 +336,7 @@ class ReactDatatable extends Component {
let cellData = ReactDOMServer.renderToStaticMarkup(column.cell(record, i));
cellData = this.strip(cellData);
newRecord[column.key] = cellData;
} else if (record[column.key]) {
} else if (record[column.key]!==undefined) {
let colValue = record[column.key];
colValue = (typeof colValue === "string") ? colValue.replace(/"/g, '""') : colValue;
newRecord[column.key] = '"' + colValue + '"';
Expand Down

0 comments on commit 871a747

Please sign in to comment.