From 565daee98ba5024fb5436acf8121840b60eb6ccd Mon Sep 17 00:00:00 2001 From: ed Date: Wed, 8 May 2024 20:08:11 +0000 Subject: [PATCH] fix mimetype detection for uppercase file extensions --- copyparty/util.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/copyparty/util.py b/copyparty/util.py index 643fc91e..4e344f88 100644 --- a/copyparty/util.py +++ b/copyparty/util.py @@ -2681,7 +2681,7 @@ def unescape_cookie(orig: str) -> str: def guess_mime(url: str, fallback: str = "application/octet-stream") -> str: try: - _, ext = url.rsplit(".", 1) + ext = url.rsplit(".", 1)[1].lower() except: return fallback