Skip to content

Commit

Permalink
fix exeption
Browse files Browse the repository at this point in the history
  • Loading branch information
EngRajabi authored and raman-m committed Oct 13, 2023
1 parent b5cc673 commit 6d64de8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public async Task Invoke(HttpContext httpContext)
$"{httpContext.Request.Path} is an authenticated route. {MiddlewareName} checking if client is authenticated");

var token = httpContext.Request.Headers
.First(r => r.Key.Equals("Authorization", StringComparison.OrdinalIgnoreCase));
.FirstOrDefault(r => r.Key.Equals("Authorization", StringComparison.OrdinalIgnoreCase));

var cacheKey = $"identityToken.{token}";

Expand Down

0 comments on commit 6d64de8

Please sign in to comment.