Utils: Add UTF8 encoding without BOM
This commit is contained in:
@ -2,7 +2,6 @@ using System;
|
||||
using System.Threading.Tasks;
|
||||
using System.IO;
|
||||
using Elwig.Helpers;
|
||||
using System.Text;
|
||||
|
||||
namespace Elwig.Documents {
|
||||
public abstract class Document : IDisposable {
|
||||
@ -63,7 +62,7 @@ namespace Elwig.Documents {
|
||||
public async Task Generate() {
|
||||
var pdf = new TempFile("pdf");
|
||||
using (var tmpHtml = new TempFile("html")) {
|
||||
await File.WriteAllTextAsync(tmpHtml.FilePath, await Render(), Encoding.UTF8);
|
||||
await File.WriteAllTextAsync(tmpHtml.FilePath, await Render(), Utils.UTF8);
|
||||
await Pdf.Convert(tmpHtml.FilePath, pdf.FilePath);
|
||||
}
|
||||
PdfFile = pdf;
|
||||
|
Reference in New Issue
Block a user