From 70aed820da4e436d215d51b020877366a36482bb Mon Sep 17 00:00:00 2001 From: Henrik Giesel Date: Mon, 26 Oct 2020 23:32:38 +0100 Subject: [PATCH] Set MIME type for javascript files --- qt/aqt/mediasrv.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/qt/aqt/mediasrv.py b/qt/aqt/mediasrv.py index 8c5d8c91f..be5a2d1bb 100644 --- a/qt/aqt/mediasrv.py +++ b/qt/aqt/mediasrv.py @@ -131,6 +131,8 @@ def allroutes(pathin): if fullpath.endswith(".css"): # some users may have invalid mime type in the Windows registry mimetype = "text/css" + elif fullpath.endswith(".js"): + mimetype = "application/javascript" else: # autodetect mimetype = None