Use file scoped namepace
This commit is contained in:
@@ -4,31 +4,30 @@ using Microsoft.AspNetCore.Builder;
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.Extensions.Hosting;
|
||||
|
||||
namespace GerstITS.Examples.Api
|
||||
namespace GerstITS.Examples.Api;
|
||||
|
||||
public class Startup : BootstrapperStartupBase
|
||||
{
|
||||
public class Startup : BootstrapperStartupBase
|
||||
#region Methods
|
||||
|
||||
protected override void ConfigureApplication(IApplicationBuilder applicationBuilder, IWebHostEnvironment webHostEnvironment)
|
||||
{
|
||||
#region Methods
|
||||
if (webHostEnvironment.IsProduction())
|
||||
applicationBuilder.UsePreconfiguredHsts();
|
||||
else
|
||||
applicationBuilder.UseDeveloperExceptionPage()
|
||||
.UseSwagger();
|
||||
|
||||
protected override void ConfigureApplication(IApplicationBuilder applicationBuilder, IWebHostEnvironment webHostEnvironment)
|
||||
{
|
||||
if (webHostEnvironment.IsProduction())
|
||||
applicationBuilder.UsePreconfiguredHsts();
|
||||
else
|
||||
applicationBuilder.UseDeveloperExceptionPage()
|
||||
.UseSwagger();
|
||||
|
||||
applicationBuilder.UsePreconfiguredCors()
|
||||
.UsePreconfiguredForwardedHeaders()
|
||||
.UsePreconfiguredHttpsRedirection()
|
||||
.UseAuthentication()
|
||||
.UseAuthorization()
|
||||
.UseRouting()
|
||||
.UseEndpoints(endpoints => endpoints.MapControllers())
|
||||
.UseRewriteUnknownPathsToIndexSite(ApplicationEnvironment.WebApi.BaseUrl)
|
||||
.UseSystemIndependentStaticFiles();
|
||||
}
|
||||
|
||||
#endregion
|
||||
applicationBuilder.UsePreconfiguredCors()
|
||||
.UsePreconfiguredForwardedHeaders()
|
||||
.UsePreconfiguredHttpsRedirection()
|
||||
.UseAuthentication()
|
||||
.UseAuthorization()
|
||||
.UseRouting()
|
||||
.UseEndpoints(endpoints => endpoints.MapControllers())
|
||||
.UseRewriteUnknownPathsToIndexSite(ApplicationEnvironment.WebApi.BaseUrl)
|
||||
.UseSystemIndependentStaticFiles();
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
Reference in New Issue
Block a user