aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Herkt <lachs0r@srsfckn.biz>2016-11-23 01:03:49 +0100
committerMartin Herkt <lachs0r@srsfckn.biz>2016-11-23 01:03:49 +0100
commit6de22ca8fa1cc71b21984278b4c50dd5559de6ee (patch)
tree5efd48fd584961904543e1da5b634956c583247d
parentfix text/ MIME charset workaround (diff)
downloadhex-zero-6de22ca8fa1cc71b21984278b4c50dd5559de6ee.tar.gz
hex-zero-6de22ca8fa1cc71b21984278b4c50dd5559de6ee.tar.bz2
hex-zero-6de22ca8fa1cc71b21984278b4c50dd5559de6ee.zip
fix text/ MIME charset workaround for real
-rwxr-xr-xfhost.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/fhost.py b/fhost.py
index ce48c03..38874c1 100755
--- a/fhost.py
+++ b/fhost.py
@@ -143,7 +143,7 @@ def store_file(f, addr):
if mime in app.config["FHOST_MIME_BLACKLIST"] or guessmime in app.config["FHOST_MIME_BLACKLIST"]:
abort(415)
- if mime.startswith("text/") and not "charset" in f.content_type:
+ if mime.startswith("text/") and not "charset" in mime:
mime += "; charset=utf-8"
ext = os.path.splitext(f.filename)[1]
bgstack15