public void Save(User user)
 {
     if (!user.IsPersistent)
     {
         user.MarkPersistent(Convert.ToInt32(_typedUserClient.GetNextSequence()));
         _typedUserClient.Store(user);
         _typedUserNameLookupClient.Store(new UserNameLookup {UserId = user.Id, Username = user.Username});
     }
     else
     {
         _typedUserClient.Store(user);
     }
 }
 public override string CreateUserAndAccount(string userName, string password, bool requireConfirmation,
                                             IDictionary<string, object> values)
 {
     var user = new User(userName, password);
     _userRepository.Save(user);
     return user.ConfirmationToken;
 }