Skip to content

Commit 4dd54a1

Browse files
Update to SixLabors.ImageSharp.Web 1.0.4 and remove processing order workarounds
1 parent de12605 commit 4dd54a1

File tree

2 files changed

+3
-12
lines changed

2 files changed

+3
-12
lines changed

src/Umbraco.Web.Common/DependencyInjection/UmbracoBuilder.ImageSharp.cs

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public static IServiceCollection AddUmbracoImageSharp(this IUmbracoBuilder build
2727

2828
builder.Services.AddImageSharp(options =>
2929
{
30-
// The configuration is set using ImageSharpConfigurationOptions
30+
// options.Configuration is set using ImageSharpConfigurationOptions below
3131
options.BrowserMaxAge = imagingSettings.Cache.BrowserMaxAge;
3232
options.CacheMaxAge = imagingSettings.Cache.CacheMaxAge;
3333
options.CachedNameLength = imagingSettings.Cache.CachedNameLength;
@@ -52,16 +52,7 @@ public static IServiceCollection AddUmbracoImageSharp(this IUmbracoBuilder build
5252
};
5353
})
5454
.Configure<PhysicalFileSystemCacheOptions>(options => options.CacheFolder = builder.BuilderHostingEnvironment.MapPathContentRoot(imagingSettings.Cache.CacheFolder))
55-
// We need to add CropWebProcessor before ResizeWebProcessor (until https://github.com/SixLabors/ImageSharp.Web/issues/182 is fixed)
56-
.RemoveProcessor<ResizeWebProcessor>()
57-
.RemoveProcessor<FormatWebProcessor>()
58-
.RemoveProcessor<BackgroundColorWebProcessor>()
59-
.RemoveProcessor<JpegQualityWebProcessor>()
60-
.AddProcessor<CropWebProcessor>()
61-
.AddProcessor<ResizeWebProcessor>()
62-
.AddProcessor<FormatWebProcessor>()
63-
.AddProcessor<BackgroundColorWebProcessor>()
64-
.AddProcessor<JpegQualityWebProcessor>();
55+
.AddProcessor<CropWebProcessor>();
6556

6657
builder.Services.AddTransient<IConfigureOptions<ImageSharpMiddlewareOptions>, ImageSharpConfigurationOptions>();
6758

src/Umbraco.Web.Common/Umbraco.Web.Common.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<PackageReference Include="MiniProfiler.AspNetCore.Mvc" Version="4.2.22" />
3535
<PackageReference Include="NETStandard.Library" Version="2.0.3" />
3636
<PackageReference Include="Serilog.AspNetCore" Version="4.1.0" />
37-
<PackageReference Include="SixLabors.ImageSharp.Web" Version="1.0.3" />
37+
<PackageReference Include="SixLabors.ImageSharp.Web" Version="1.0.4" />
3838
<PackageReference Include="Smidge.Nuglify" Version="4.0.0" />
3939
<PackageReference Include="Smidge.InMemory" Version="4.0.0" />
4040
<PackageReference Include="Dazinator.Extensions.FileProviders" Version="2.0.0" />

0 commit comments

Comments
 (0)