Cannot read property 'filter' of undefined when pressing Enter Key
See original GitHub issueHi guys it seems like there is a bug in version 1.1.0. It can be reproduced by typing a few characters and then pressing Enter key. I am using the following code to test it:
<Creatable
multi={true}
value={this.state.value}
promptTextCreator={text =>
`Add ${text} To List` }
placeholder={'Enter Your Answers'}
onBlurResetsInput={true}
/>
This is the error I get:
Uncaught TypeError: Cannot read property 'filter' of undefined at isOptionUnique (bundle.js:30499) at CreatableSelect.isOptionUnique (bundle.js:30376) at CreatableSelect.createNewOption (bundle.js:30304) at CreatableSelect.onInputKeyDown (bundle.js:30419) at Select.handleKeyDown (bundle.js:29113) at HTMLUnknownElement.callCallback (bundle.js:7119) at Object.invokeGuardedCallbackDev (bundle.js:7158) at Object.invokeGuardedCallback (bundle.js:7015) at Object.invokeGuardedCallbackAndCatchFirstError (bundle.js:7029) at executeDispatch (bundle.js:7413) at executeDispatchesInOrder (bundle.js:7435) at executeDispatchesAndRelease (bundle.js:7533) at executeDispatchesAndReleaseTopLevel (bundle.js:7544) at Array.forEach (<anonymous>) at forEachAccumulated (bundle.js:7512) at processEventQueue (bundle.js:7689) at runEventQueueInBatch (bundle.js:10184) at handleTopLevel (bundle.js:10193) at handleTopLevelImpl (bundle.js:9924) at batchedUpdates (bundle.js:17659) at batchedUpdates (bundle.js:8907) at dispatchEvent (bundle.js:9998) isOptionUnique @ bundle.js:30499 isOptionUnique @ bundle.js:30376 createNewOption @ bundle.js:30304 onInputKeyDown @ bundle.js:30419 handleKeyDown @ bundle.js:29113 callCallback @ bundle.js:7119 invokeGuardedCallbackDev @ bundle.js:7158 invokeGuardedCallback @ bundle.js:7015 invokeGuardedCallbackAndCatchFirstError @ bundle.js:7029 executeDispatch @ bundle.js:7413 executeDispatchesInOrder @ bundle.js:7435 executeDispatchesAndRelease @ bundle.js:7533 executeDispatchesAndReleaseTopLevel @ bundle.js:7544 forEachAccumulated @ bundle.js:7512 processEventQueue @ bundle.js:7689 runEventQueueInBatch @ bundle.js:10184 handleTopLevel @ bundle.js:10193 handleTopLevelImpl @ bundle.js:9924 batchedUpdates @ bundle.js:17659 batchedUpdates @ bundle.js:8907 dispatchEvent @ bundle.js:9998
Thanks
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (2 by maintainers)
Why is still this open? I updated to ^1.2.1 and fixed!
Hello -
In an effort to sustain the
react-select
project going forward, we’re closing old issues / pull requests.We understand this might be inconvenient but in the best interest of supporting the broader community we have to direct our limited efforts to maintain the latest version.
If you feel this issue / pull request is still relevant and you’d like us to review it, please leave a comment and we’ll do our best to get back to you.