Skip to content

Commit 62dd766

Browse files
author
Tiago Brenck
committed
Fix for #363
1 parent fff4d92 commit 62dd766

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

4-WebApp-your-API/4-2-B2C/README.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -266,8 +266,13 @@ using Microsoft.Identity.Web.Client.TokenCacheProviders;
266266
with
267267
268268
```Csharp
269-
services.AddProtectedWebApi(Configuration)
270-
.AddInMemoryTokenCaches();
269+
services.AddProtectedWebApi(options =>
270+
{
271+
Configuration.Bind("AzureAdB2C", options);
272+
273+
options.TokenValidationParameters.NameClaimType = "name";
274+
},
275+
options => { Configuration.Bind("AzureAdB2C", options); });
271276
```
272277
- Add the method **app.UseAuthentication()** before **app.UseMvc()** in the `Configure` method
273278

0 commit comments

Comments
 (0)