To give more information on the error: Someone can correct me on this if I am wrong…
The passed event is attached to the function. So, using another function to set the state with event used within it, is kind-of like asking for the event of the setState callback, and not the onChange => handleChange callback.
Essentially, if you want to use the method above, you need to do something like:
Unless you need the current state you shouldn’t use an updater function. Using an updater function is problematic with event handling because of how React deals with events.
More info with some links:
Edit: I guess it would be nice if the challenge failed but I’m not sure what changes that would take or if it’s feasible.