From 15c38b6b92b5fda28041fea0cbaed5a14e04d175 Mon Sep 17 00:00:00 2001
From: Markin Igor <markin.io210@gmail.com>
Date: Mon, 2 Dec 2019 16:51:08 +0200
Subject: [PATCH] Strip name from content type

---
 javascript/src/helpers/mailparser.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/javascript/src/helpers/mailparser.js b/javascript/src/helpers/mailparser.js
index 94dbb07..cf9b9c8 100644
--- a/javascript/src/helpers/mailparser.js
+++ b/javascript/src/helpers/mailparser.js
@@ -318,7 +318,7 @@ export function getHTML(mime, parts) {
         continue;
       }
       console.log("CID2", contentId);
-      contentType = contentType[0];
+      contentType = contentType[0].split(";")[0];
       console.log("ContentTYpe", contentType);
       const normalizedBody = getBody(mime, parts[i]).replace(newline, "");
       const src = "data:" + contentType + ";base64, " + normalizedBody;
-- 
GitLab