-
Notifications
You must be signed in to change notification settings - Fork 363
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix the error while passing any data except string for normalization #868
Conversation
.toLowerCase() | ||
.includes(accentFold(searchTerm).toLowerCase()) | ||
typeof option.value === "string" | ||
? accentFold(option.value) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Found that option.value
is not always string. Especially, when using a <Facet isFilterable={true} />
on a field like date_established
, it becomes an object
.
093eaec
to
0e0c448
Compare
0e0c448
to
75f178d
Compare
@JasonStoltz @joemcelroy review? |
thanks for the PR @atiqueahmedziad! Will review later on today. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. Thanks for your submission,
this was released under v1.18.1 🎉 |
…lastic#868) Co-authored-by: Joseph McElroy <joseph.mcelroy@elastic.co>
Description
When using a
<Facet isFilterable={true} />
on a field mapped toNUMBER
, we get the following error:Uncaught TypeError: str.normalize is not a function
List of changes
accentFold
function, it should return empty string.Associated Github Issues
Fixes #833