Skip to content

Commit 45a84bc

Browse files
committed
Reverted DinkPdf changes because it doen't work on Linux, mac
1 parent 20af421 commit 45a84bc

File tree

4 files changed

+0
-101
lines changed

4 files changed

+0
-101
lines changed

src/Modules/SimplCommerce.Module.DinkToPdf/CustomAssemblyLoadContext.cs

Lines changed: 0 additions & 29 deletions
This file was deleted.

src/Modules/SimplCommerce.Module.DinkToPdf/ModuleInitializer.cs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,15 @@
33
using Microsoft.AspNetCore.Builder;
44
using Microsoft.AspNetCore.Hosting;
55
using Microsoft.Extensions.DependencyInjection;
6-
using SimplCommerce.Infrastructure.Helpers;
76
using SimplCommerce.Infrastructure.Modules;
87
using SimplCommerce.Module.Core.Services;
9-
using System.IO;
108

119
namespace SimplCommerce.Module.DinkToPdf
1210
{
1311
public class ModuleInitializer : IModuleInitializer
1412
{
1513
public void ConfigureServices(IServiceCollection serviceCollection)
1614
{
17-
var context = new CustomAssemblyLoadContext();
18-
context.LoadUnmanagedLibrary(Path.Combine(Directory.GetCurrentDirectory(), "libwkhtmltox.dll"));
19-
2015
serviceCollection.AddSingleton(typeof(IConverter), new SynchronizedConverter(new PdfTools()));
2116
serviceCollection.AddTransient<IPdfConverter, DinkToPdfConverter>();
2217
}

src/SimplCommerce.Infrastructure/Helpers/CurrentDirectoryHelper.cs

Lines changed: 0 additions & 63 deletions
This file was deleted.

src/SimplCommerce.WebHost/Program.cs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
using Microsoft.Extensions.Configuration;
55
using Microsoft.Extensions.Logging;
66
using Serilog;
7-
using SimplCommerce.Infrastructure.Helpers;
87
using SimplCommerce.Module.Core.Extensions;
98

109
namespace SimplCommerce.WebHost
@@ -15,9 +14,6 @@ public static void Main(string[] args)
1514
{
1615
try
1716
{
18-
//TODO: Remove this fix for 2.2 `SetCurrentDirectory` when/if move to dotnet 3.0
19-
CurrentDirectoryHelper.SetCurrentDirectory();
20-
2117
BuildWebHost2(args).Run();
2218
}
2319
catch(Exception ex)

0 commit comments

Comments
 (0)