summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--core/views/expo.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/core/views/expo.py b/core/views/expo.py
index 6ce9cb7..3e75e5e 100644
--- a/core/views/expo.py
+++ b/core/views/expo.py
@@ -305,8 +305,16 @@ def getmimetype(path):
"""Our own version rather than relying on what is provided by the python library. Note that when
Apache or nginx is used to deliver /expofiles/ it will use it's own idea of mimetypes and
not these.
+
+ This sets the Content Type in the HTTP header, e.g.
+ Content-Type: text/html; charset=utf-8
"""
path = str(path)
+
+ if path.lower().endswith("gpx"):
+ return "application/octet-stream"
+ if path.lower().endswith("kml"):
+ return "application/octet-stream"
if path.lower().endswith(".css"):
return "text/css"
if path.lower().endswith(".txt"):