Skip to content

Commit

Permalink
Fix intermittent redirects during external auto-login (#17220)
Browse files Browse the repository at this point in the history
  • Loading branch information
MikeAlhayek authored Dec 12, 2024
1 parent aa631d0 commit 87a21fe
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,14 @@ public ExternalLoginFormEvents(
_httpContextAccessor = httpContextAccessor;
}

public override Task LoggedInAsync(IUser user)
{
var tempData = _tempDataDictionaryFactory.GetTempData(_httpContextAccessor.HttpContext);
tempData.Remove(ExternalLoginAutoRedirectKeyName);

return Task.CompletedTask;
}

public override async Task<IActionResult> LoggingInAsync()
{
if (!_externalLoginOptions.UseExternalProviderIfOnlyOneDefined)
Expand Down

0 comments on commit 87a21fe

Please sign in to comment.