From 52851a8e52ac638ef005c4bd38b1d5edf6e52cee Mon Sep 17 00:00:00 2001 From: M66B Date: Wed, 27 Oct 2021 09:28:21 +0200 Subject: [PATCH] Workaround for incorrect audio/mid mime type --- app/src/main/java/eu/faircode/email/EntityAttachment.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/EntityAttachment.java b/app/src/main/java/eu/faircode/email/EntityAttachment.java index 9bb5e79364..a231f4b953 100644 --- a/app/src/main/java/eu/faircode/email/EntityAttachment.java +++ b/app/src/main/java/eu/faircode/email/EntityAttachment.java @@ -182,9 +182,6 @@ public class EntityAttachment { if ("docx".equals(extension)) return "application/vnd.openxmlformats-officedocument.wordprocessingml.document"; - if ("mid".equals(extension) || "midi".equals(extension)) - return "audio/midi"; - if ("xls".equals(extension)) return "application/vnd.ms-excel"; @@ -207,6 +204,9 @@ public class EntityAttachment { if ("text/plain".equals(type) && "ovpn".equals(extension)) return "application/x-openvpn-profile"; + if ("audio/mid".equals(type)) + return "audio/midi"; + // https://www.rfc-editor.org/rfc/rfc3555.txt if ("video/jpeg".equals(type)) return "image/jpeg";