Skip to content

Commit

Permalink
fix #58 on py26 ??
Browse files Browse the repository at this point in the history
  • Loading branch information
ikirudennis committed Nov 15, 2017
1 parent e26c454 commit 426abbe
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions textile/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ def generate_tag(tag, content, attributes=None):
# Python 2.6 doesn't have the tostringlist method, so we have to treat
# it differently.
element_tag = ElementTree.tostring(element, encoding=enc)
element_tag = [v.decode(enc) for v in element_tag]
element_text = re.sub(r"<\?xml version='1.0' encoding='UTF-8'\?>\n",
'', element_tag)
if content != six.text_type(' /'):
Expand Down

0 comments on commit 426abbe

Please sign in to comment.