aboutsummaryrefslogtreecommitdiffstats
path: root/server.py
diff options
context:
space:
mode:
Diffstat (limited to 'server.py')
-rw-r--r--server.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/server.py b/server.py
index 692fe8c..e2e93f0 100644
--- a/server.py
+++ b/server.py
@@ -119,8 +119,8 @@ def render_file(path):
)
if os.path.isfile(abs_path):
if abs_path.endswith('.html'):
- with open(abs_path) as f:
- content = f.read()
+ with open(abs_path, 'rb') as f:
+ content = f.read().decode("UTF-8")
return render_template_string(CONTENT_BLOCK.replace('$', content), **context)
elif abs_path.endswith('.html!'):
return render_template("site/" + path, **context)