Merge remote-tracking branch 'origin/netcore/dev' into netcore/feature/AB5822-smidge-implementation

# Conflicts:
#	src/Umbraco.Web.BackOffice/AspNetCore/UmbracoCoreServiceCollectionExtensions.cs
#	src/Umbraco.Web.UI.NetCore/Startup.cs
#	src/Umbraco.Web/Editors/PackageInstallController.cs
#	src/Umbraco.Web/UrlHelperExtensions.cs
This commit is contained in:
Bjarke Berg
2020-03-26 06:51:23 +01:00
114 changed files with 2433 additions and 819 deletions

View File

@@ -16,21 +16,30 @@ namespace Umbraco.Web.UI.BackOffice
{
public class Startup
{
private readonly IConfiguration _configuration;
private readonly IWebHostEnvironment _webHostEnvironment;
private readonly IConfiguration _config;
public Startup(IConfiguration configuration)
/// <summary>
/// Constructor
/// </summary>
/// <param name="webHostEnvironment"></param>
/// <param name="config"></param>
/// <remarks>
/// Only a few services are possible to be injected here https://github.com/dotnet/aspnetcore/issues/9337
/// </remarks>
public Startup(IWebHostEnvironment webHostEnvironment, IConfiguration config)
{
_configuration = configuration;
_webHostEnvironment = webHostEnvironment ?? throw new ArgumentNullException(nameof(webHostEnvironment));
_config = config ?? throw new ArgumentNullException(nameof(config));
}
// This method gets called by the runtime. Use this method to add services to the container.
// For more information on how to configure your application, visit https://go.microsoft.com/fwlink/?LinkID=398940
public void ConfigureServices(IServiceCollection services)
{
services.AddUmbracoConfiguration();
services.AddUmbracoRuntimeMinifier(_configuration);
services.AddUmbracoCore();
services.AddUmbracoConfiguration(_config);
services.AddUmbracoRuntimeMinifier(_config);
services.AddUmbracoCore(_webHostEnvironment);
services.AddUmbracoWebsite();
}