Rev1941, Use utf-8 encoding on text files
This commit is contained in:
parent
819f765bce
commit
c95637eee1
2 changed files with 4 additions and 1 deletions
|
@ -10,7 +10,7 @@ class Config(object):
|
||||||
|
|
||||||
def __init__(self, argv):
|
def __init__(self, argv):
|
||||||
self.version = "0.5.2"
|
self.version = "0.5.2"
|
||||||
self.rev = 1940
|
self.rev = 1941
|
||||||
self.argv = argv
|
self.argv = argv
|
||||||
self.action = None
|
self.action = None
|
||||||
self.config_file = "zeronet.conf"
|
self.config_file = "zeronet.conf"
|
||||||
|
|
|
@ -157,6 +157,9 @@ class UiRequest(object):
|
||||||
|
|
||||||
if content_type == "text/html":
|
if content_type == "text/html":
|
||||||
content_type = "text/html; charset=utf-8"
|
content_type = "text/html; charset=utf-8"
|
||||||
|
if content_type == "text/plain":
|
||||||
|
content_type = "text/plain; charset=utf-8"
|
||||||
|
|
||||||
cacheable_type = (
|
cacheable_type = (
|
||||||
content_type == "text/css" or content_type.startswith("image") or content_type.startswith("video") or
|
content_type == "text/css" or content_type.startswith("image") or content_type.startswith("video") or
|
||||||
self.env["REQUEST_METHOD"] == "OPTIONS" or content_type == "application/javascript"
|
self.env["REQUEST_METHOD"] == "OPTIONS" or content_type == "application/javascript"
|
||||||
|
|
Loading…
Reference in a new issue