Skip to content

Commit

Permalink
fix: null check on nullable itemSearch prop
Browse files Browse the repository at this point in the history
  • Loading branch information
codeofmochi committed Jul 6, 2021
1 parent 3cede4f commit 8792947
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/main/ItemsGrid.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class ItemsGrid extends Component {
const { title, itemSearch } = this.props;
return (
<div>
<TableToolbar tableTitle={title} itemSearchInput={itemSearch.input} />
<TableToolbar tableTitle={title} itemSearchInput={itemSearch?.input} />
<Grid container spacing={1}>
{this.renderItems()}
</Grid>
Expand Down
2 changes: 1 addition & 1 deletion src/components/main/ItemsTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ const ItemsTable = ({ items: rows, tableTitle, id: tableId, itemSearch }) => {
tableTitle={tableTitle}
numSelected={selected.length}
selected={selected}
itemSearchInput={itemSearch.input}
itemSearchInput={itemSearch?.input}
/>
<TableContainer>
<Table
Expand Down

0 comments on commit 8792947

Please sign in to comment.