react-awesome-query-builder icon indicating copy to clipboard operation
react-awesome-query-builder copied to clipboard

toUpperCase() gives an error if multiselect number comes up.

Open RackweLLizm opened this issue 7 months ago • 3 comments

toUpperCase will give an error if a value of number type is received in a multiselect field.

Error Path: node_modules@react-awesome-query-builder\core\esm\utils\autocomplete.js

filtered = listValuesToArray(all).filter(function (_ref3) { var title = _ref3.title, value = _ref3.value; return search == null ? true : title.toUpperCase().indexOf(search.toUpperCase()) != -1 || "".concat(value).toUpperCase().indexOf(search.toUpperCase()) != -1; });

added part; return search == null ? true : title.toString().toUpperCase().indexOf(search.toUpperCase()) != -1 || "".concat(value).toUpperCase().indexOf(search.toUpperCase()) != -1;

RackweLLizm avatar May 05 '25 09:05 RackweLLizm

@ukrbublik I can PR this if you want

RackweLLizm avatar May 09 '25 17:05 RackweLLizm

Yes please

ukrbublik avatar May 09 '25 17:05 ukrbublik

Hi am legend4tech I can give this issue a try if U can explain how I will run the project to get to the affected file like how to see the error U showed above and the file to manipulate to solve the issue If I get this explanation I will help out properly looking forward to be assigned and get proper explanation

legend4tech avatar Jun 30 '25 15:06 legend4tech