Validate scopes in Development environment in CreateDefaultBuilder (#61)
This commit is contained in:
parent
a7abb0d78f
commit
d4f39bf56b
|
|
@ -181,6 +181,10 @@ namespace Microsoft.AspNetCore
|
||||||
logging.AddDebug();
|
logging.AddDebug();
|
||||||
})
|
})
|
||||||
.UseIISIntegration()
|
.UseIISIntegration()
|
||||||
|
.UseDefaultServiceProvider((context, options) =>
|
||||||
|
{
|
||||||
|
options.ValidateScopes = context.HostingEnvironment.IsDevelopment();
|
||||||
|
})
|
||||||
.ConfigureServices(services =>
|
.ConfigureServices(services =>
|
||||||
{
|
{
|
||||||
services.AddSingleton<IStartupFilter, WebHostStartupFilter>();
|
services.AddSingleton<IStartupFilter, WebHostStartupFilter>();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue