Skip to content

Commit

Permalink
fix: data is undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
nextchamp-saqib authored Jan 2, 2024
1 parent 98835d8 commit b3ff486
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/filterRows.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,11 @@ function getFilterMethod(rows, data, filter) {
let formatter = CellManager.getCustomCellFormatter(cell);
if (data && data.constructor.name === 'DataManager') {
data = data.getData(cell.rowIndex);
} else {
data = rows[cell.rowIndex]
}
if (formatter && cell.content) {
cell.html = formatter(cell.content, rows[cell.rowIndex], cell.column, rows[cell.rowIndex], filter, data);
cell.html = formatter(cell.content, rows[cell.rowIndex], cell.column, data, filter);
return stripHTML(cell.html);
}
return cell.content || '';
Expand Down

0 comments on commit b3ff486

Please sign in to comment.