1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-11-26 22:41:17 +02:00

Desktop: Fixes #11759: Preserve attachment file extensions regardless of the mime type (#11852)

Co-authored-by: Laurent Cozic <laurent22@users.noreply.github.com>
This commit is contained in:
pedr
2025-02-18 15:17:23 -03:00
committed by GitHub
parent c8640aa7f8
commit 8a28edcda8
2 changed files with 14 additions and 2 deletions

View File

@@ -344,7 +344,7 @@ function shimInit(options: ShimInitOptions = null) {
const detectedType = await fileTypeFromFile(filePath);
if (detectedType) {
fileExt = detectedType.ext;
fileExt = fileExt ? fileExt : detectedType.ext;
resource.mime = detectedType.mime;
} else {
resource.mime = 'application/octet-stream';