private static string CheckAccountInfoIsValid(string username, string password, string email) { if (username.Length < 3) { return(ResErrors.RegisterUsernameInvalid); } if (Passwords.IsPasswordValid(password)) { return(ResErrors.RegisterPasswordInvalid); } if (!IsValidEmail(email)) { return(ResErrors.RegisterEmailInvalid); } return("Valid"); }