Skip to content

Commit

Permalink
fix: Adjust sample
Browse files Browse the repository at this point in the history
  • Loading branch information
ellinge committed Jun 27, 2019
1 parent cdde599 commit c3c9c5e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ Optional search predicate to override the default case insensitive contains matc

```jsx
function searchPredicate(node, searchTerm) {
return (node.label + ' ' + node.customData).toLower().indexOf(searchTerm) >= 0
return node.customData && node.customData.toLower().indexOf(searchTerm) >= 0
}

return <DropdownTreeSelect data={data} searchPredicate={searchPredicate} />
Expand Down

0 comments on commit c3c9c5e

Please sign in to comment.