From a65664bfcb76814a750b6dd6e1f38974bcee22be Mon Sep 17 00:00:00 2001
From: Oleg Broytman
Date: Sun, 8 Jun 2014 20:56:09 +0400
Subject: [PATCH] Encode unicode to utf-8
---
phd.py | 2 ++
1 file changed, 2 insertions(+)
diff --git a/phd.py b/phd.py
index d1821b1..52f6937 100644
--- a/phd.py
+++ b/phd.py
@@ -54,6 +54,8 @@ class phd(Template):
new_paras = []
for p in paragraphs:
+ if isinstance(p, unicode):
+ p = p.encode('utf-8')
parts = p.split("\n ")
parts[0] = parts[0].strip()
new_paras.append('\n
\n\n'.join(parts))
--
2.39.5