fixed typos
fix: even if showSignupCode was set to false null was compared to undefined and an error was thrown with no signupCode
fix: if username was required the email field was checked