From 94f6d8a70d560a36d90eb9f9dc261a01892c9f16 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Thu, 7 Sep 2017 14:52:46 +1000 Subject: [PATCH] force correct css mime type fixes broken styling on machines with an incorrect mime type --- aqt/mediasrv.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/aqt/mediasrv.py b/aqt/mediasrv.py index ca6bb1d36..dd85f8ca7 100644 --- a/aqt/mediasrv.py +++ b/aqt/mediasrv.py @@ -107,3 +107,6 @@ class RequestHandler(http.server.SimpleHTTPRequestHandler): newPath = os.path.join(_exportFolder, path[len(targetPath)+1:]) return newPath return path + +# work around Windows machines with incorrect mime type +RequestHandler.extensions_map['.css'] = "text/css"