public static bool AddNewUser(User newUser) { bool userChecker = UserPersistence.CheckUsername(newUser); if (userChecker == true) { string salt = EncryptionManager.PasswordSalt; newUser.HashPassword = EncryptionManager.EncodePassword(newUser.Password, salt); newUser.Salt = salt; newUser.Status = 0; newUser.IsAdmin = 0; return(UserPersistence.AddUser(newUser)); } return(false); }