Reacting to DependencyInjection changes
This commit is contained in:
parent
c82ac5e61f
commit
1c39930b16
|
|
@ -350,7 +350,7 @@ namespace Microsoft.AspNet.Antiforgery
|
||||||
private static IServiceProvider GetServiceProvider(IAntiforgeryContextAccessor contextAccessor)
|
private static IServiceProvider GetServiceProvider(IAntiforgeryContextAccessor contextAccessor)
|
||||||
{
|
{
|
||||||
var serviceCollection = new ServiceCollection();
|
var serviceCollection = new ServiceCollection();
|
||||||
serviceCollection.AddInstance<IAntiforgeryContextAccessor>(contextAccessor);
|
serviceCollection.AddSingleton(contextAccessor);
|
||||||
return serviceCollection.BuildServiceProvider();
|
return serviceCollection.BuildServiceProvider();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue