1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-01 08:02:49 -05:00

build jwtoptions from JwtBearerAppBuilderExtensions

This commit is contained in:
Kyle Spearrin
2017-01-21 23:35:20 -05:00
parent 220243c8b4
commit 97c14100d2
2 changed files with 9 additions and 4 deletions

View File

@ -104,8 +104,8 @@ namespace Bit.Api.IdentityServer
var httpContext = _httpContextAccessor.HttpContext;
_userManager = httpContext.RequestServices.GetRequiredService<UserManager<User>>();
_identityOptions = httpContext.RequestServices.GetRequiredService<IOptions<IdentityOptions>>()?.Value ?? new IdentityOptions();
_jwtBearerOptions = httpContext.RequestServices.GetRequiredService<IOptions<JwtBearerOptions>>()?.Value;
_jwtBearerIdentityOptions = httpContext.RequestServices.GetRequiredService<IOptions<JwtBearerIdentityOptions>>()?.Value;
_jwtBearerOptions = Core.Identity.JwtBearerAppBuilderExtensions.BuildJwtBearerOptions(_jwtBearerIdentityOptions);
}
private void BuildSuccessResult(User user, ResourceOwnerPasswordValidationContext context)