Reacting to DependencyInjection changes

This commit is contained in:
Pranav K 2015-11-13 10:33:23 -08:00
parent c82ac5e61f
commit 1c39930b16
1 changed files with 1 additions and 1 deletions

View File

@ -350,7 +350,7 @@ namespace Microsoft.AspNet.Antiforgery
private static IServiceProvider GetServiceProvider(IAntiforgeryContextAccessor contextAccessor)
{
var serviceCollection = new ServiceCollection();
serviceCollection.AddInstance<IAntiforgeryContextAccessor>(contextAccessor);
serviceCollection.AddSingleton(contextAccessor);
return serviceCollection.BuildServiceProvider();
}