Fix renamed IContextAccessor APIs.

This commit is contained in:
Chris Ross 2014-04-30 15:43:21 -07:00
parent 7b4e1fd48e
commit 61924dd73e
1 changed files with 4 additions and 4 deletions

View File

@ -93,8 +93,8 @@ namespace Microsoft.AspNet.RequestContainer
httpContext.ApplicationServices = appServiceProvider; httpContext.ApplicationServices = appServiceProvider;
httpContext.RequestServices = scopeServiceProvider; httpContext.RequestServices = scopeServiceProvider;
var priorAppHttpContext = appHttpContextAccessor.ExchangeValue(httpContext); var priorAppHttpContext = appHttpContextAccessor.SetValue(httpContext);
var priorScopeHttpContext = scopeHttpContextAccessor.ExchangeValue(httpContext); var priorScopeHttpContext = scopeHttpContextAccessor.SetValue(httpContext);
try try
{ {
@ -102,8 +102,8 @@ namespace Microsoft.AspNet.RequestContainer
} }
finally finally
{ {
scopeHttpContextAccessor.ExchangeValue(priorScopeHttpContext); scopeHttpContextAccessor.SetValue(priorScopeHttpContext);
appHttpContextAccessor.ExchangeValue(priorAppHttpContext); appHttpContextAccessor.SetValue(priorAppHttpContext);
httpContext.RequestServices = priorRequestServices; httpContext.RequestServices = priorRequestServices;
httpContext.ApplicationServices = priorApplicationServices; httpContext.ApplicationServices = priorApplicationServices;