-
Notifications
You must be signed in to change notification settings - Fork 247
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
Multiselect error when removing only option: Uncaught TypeError: Cannot read properties of null (reading 'map')
#1182
Comments
I tried making a PR, but I cannot get the build script to run correctly using either NPM or Yarn 😕 |
Same issue here. |
Bumping, same issue here |
Any updates about this issue!? |
Also need an update on this issue! |
@vvasilev- @atanas-dev @jorostoyanov anybody else? |
Fixed and coming in next release, see here: |
The fix for this issue is now released in https://github.com/htmlburger/carbon-fields/releases/tag/v3.6.5 |
Version
Expected Behavior
Please enter the expected behavior here
I should be able to remove the last selected option from a multiselect form.
Actual Behavior
Please enter the actual, unexpected behavior here
Instead of the option getting removed, nothing happens, and I get a console error:
Uncaught TypeError: Cannot read properties of null (reading 'map')
This seems to be caused by the use of
selected.map()
instead ofselected?.map()
inhandleChange
means the value is not an array. (not sure if this is a change in behavior in react-select@v3 2de3fbeContainer definition
Steps to Reproduce the Problem
Comments
Please add any other comments here
The text was updated successfully, but these errors were encountered: