Skip to content

Commit 32a039a

Browse files
dudanogueiraalexmorozov
authored andcommitted
Force str at saveAs argument to avoid TypeError from pylokit when receiving unicode
1 parent 988891c commit 32a039a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

templated_docs/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ def fill_template(template_name, context, output_format='odt'):
134134
conv_file = NamedTemporaryFile(delete=False,
135135
suffix='.%s' % output_format)
136136
with lo.documentLoad(str(dest_file.name)) as doc:
137-
doc.saveAs(conv_file.name)
137+
doc.saveAs(str(conv_file.name))
138138
os.unlink(dest_file.name)
139139
return conv_file.name
140140
else:

0 commit comments

Comments
 (0)