Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Adolfok3 committed Apr 24, 2024
1 parent 2b17e58 commit 5787143
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,16 +150,16 @@ services.AddHttpClient("TargetApi")
```csharp
public class MyCustomInterceptor : IAuthorizationInterceptor
{
public async Task<AuthorizationEntry?> GetHeadersAsync()
public async Task<AuthorizationHeaders?> GetHeadersAsync()
{
//Do something and return the headers if exists in this context
}

public async Task<AuthorizationEntry?> UpdateHeadersAsync(AuthorizationHeaders? expiredHeaders, AuthorizationHeaders? newHeaders)
public async Task<AuthorizationHeaders?> UpdateHeadersAsync(AuthorizationHeaders? expiredHeaders, AuthorizationHeaders? newHeaders)
{
//Do something with expired headers if necessary and update with newHeaders
}
}
```

With this configuration, the Authorization Interceptor will create a sequence of: `MemoryCache > DistributedCache > MyCustomInterceptor > AuthenticationHandler > DistributedCache > MyCustomInterceptor > MemoryCache`.
With this configuration, the Authorization Interceptor will create a sequence of: `MemoryCache > DistributedCache > MyCustomInterceptor > AuthenticationHandler > DistributedCache > MyCustomInterceptor > MemoryCache`.

0 comments on commit 5787143

Please sign in to comment.