···4141 // Check that the code is correct. We do this again just incase the user enters the code after their pw and we
4242 // don't get to call onBlur first
4343 const formattedCode = checkAndFormatResetCode(resetCode)
4444- // TODO Better password strength check
4545- if (!formattedCode || !password) {
4444+4545+ if (!formattedCode) {
4646 setError(
4747 _(
4848 msg`You have entered an invalid code. It should look like XXXXX-XXXXX.`,
4949 ),
5050 )
5151+ return
5252+ }
5353+5454+ // TODO Better password strength check
5555+ if (!password) {
5656+ setError(_(msg`Please enter a password.`))
5157 return
5258 }
5359