Organization filter should not include descriptions.
isabelxklee opened this issue · 0 comments
isabelxklee commented
AC:
- Search terms should only look at the names and locations of organizations.
Note:
- The following code does not filter out description keys.
orgs = this.props.orgs.filter((org) => {
return Object.keys(org).some(key =>
typeof org[key] === "string"
&& org[key] !== "description"
?
org[key].toLowerCase().includes(this.state.searchTerm) : null
)
})