/// <summary> /// Signs a user out of the specified provider. /// </summary> /// <param name="pi">Provider information to sign out from.</param> /// <returns>Awaitable task is returned.</returns> private async Task SignoutAsync(WebAccountProviderInfo pi) { if (pi == null) { throw new ArgumentNullException(nameof(pi)); } WebAccount account = await GetWebAccount(pi.WebAccountType); // Check if the account has been deleted already by Token Broker if (account != null) { await account.SignOutAsync(); } account = null; this.DeleteUsersWebAccountDetails(pi.WebAccountType); }
/// <summary> /// Signs a user out of the specified provider. /// </summary> /// <param name="pi">Provider information to sign out from.</param> /// <returns>Awaitable task is returned.</returns> private async Task SignoutAsync(WebAccountProviderInfo pi) { if (pi == null) throw new ArgumentNullException(nameof(pi)); WebAccount account = await GetWebAccount(pi.WebAccountType); // Check if the account has been deleted already by Token Broker if (account != null) await account.SignOutAsync(); account = null; this.DeleteUsersWebAccountDetails(pi.WebAccountType); }