From b10b3af88116b0e1e435bc96b18a1d1068e5f1ca Mon Sep 17 00:00:00 2001 From: Leandro Facchinetti Date: Thu, 19 Mar 2020 11:23:19 -0400 Subject: [PATCH] . --- src/index.tsx | 2 +- src/test.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/index.tsx b/src/index.tsx index 8069225..dc0cfac 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -64,7 +64,7 @@ export const emailServer = new SMTPServer({ }); for (const path of paths) { const xml = await new xml2js.Parser().parseStringPromise( - fs.readFileSync(path).toString() + fs.readFileSync(path, "utf8") ); xml.feed.updated = now(); if (xml.feed.entry === undefined) xml.feed.entry = []; diff --git a/src/test.ts b/src/test.ts index 3960b8c..04cd386 100644 --- a/src/test.ts +++ b/src/test.ts @@ -72,5 +72,5 @@ async function createFeed(): Promise { } function readFeed(token: string): string { - return fs.readFileSync(feedPath(token)).toString(); + return fs.readFileSync(feedPath(token), "utf8"); }