Fixed password reset allowing successful reset with invalid code