From eb6c2de4569b68388b59f089547b7631e204987e Mon Sep 17 00:00:00 2001 From: pandamoon21 <33972938+pandamoon21@users.noreply.github.com> Date: Sat, 11 May 2024 23:32:47 +0700 Subject: [PATCH] Fix uppercase extension in suffix - font attachment --- devine/core/tracks/attachment.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devine/core/tracks/attachment.py b/devine/core/tracks/attachment.py index c359629..7fad38e 100644 --- a/devine/core/tracks/attachment.py +++ b/devine/core/tracks/attachment.py @@ -37,7 +37,7 @@ def __init__( mime_type = { ".ttf": "application/x-truetype-font", ".otf": "application/vnd.ms-opentype" - }.get(path.suffix, mimetypes.guess_type(path)[0]) + }.get(path.suffix.lower(), mimetypes.guess_type(path)[0]) if not mime_type: raise ValueError("The attachment mime-type could not be automatically detected.")