Hey there, I am a React developer and a problem solver, I have looked at the code, your problem is that you are not checking for conditions, I have already fixed it, please write to me if you want to understand the problem better and the code.
I would like to also give you general feedback about the project's code cause it wasn't well documented,
I would love to hear from you as soon as possible.
Have a nice day!