public async Task DeleteAccount(string username, Guid profileId, CancellationToken cancellationToken) { Ensure.String.IsNotNullOrWhiteSpace(username, nameof(username)); Ensure.Guid.IsNotEmpty(profileId, nameof(profileId)); await _photoCommand.DeletePhotos(profileId, cancellationToken).ConfigureAwait(false); await _profileCommand.DeleteProfile(profileId, cancellationToken).ConfigureAwait(false); var account = new Account(username); await _accountStore.DeleteAccount(account.Provider, account.Subject, cancellationToken).ConfigureAwait(false); await _userStore.DeleteUser(username, cancellationToken).ConfigureAwait(false); _cache.RemoveAccount(username); }
public async Task DeleteAccount(string email) { await _accountStore.DeleteAccount(email); }
/// <summary> /// 删除账号名称 /// </summary> /// <param name="accountName"></param> public void DeleteAccount(string path, string accountName) { accountStore.DeleteAccount(path, accountName); }