From 366f7a55d56b70d303200ebf46707244033b1217 Mon Sep 17 00:00:00 2001 From: Piotr Orzechowski Date: Mon, 22 Jan 2018 23:16:01 +0100 Subject: [PATCH] picoweb: Add javascript mime type. --- picoweb/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/picoweb/__init__.py b/picoweb/__init__.py index 75487e0..c440cdc 100644 --- a/picoweb/__init__.py +++ b/picoweb/__init__.py @@ -18,6 +18,8 @@ def get_mime_type(fname): return "text/html" if fname.endswith(".css"): return "text/css" + if fname.endswith(".js"): + return "text/javascript" if fname.endswith(".png") or fname.endswith(".jpg"): return "image" return "text/plain"