Skip to content

Commit 57f22bf

Browse files
change to_svg and to_png to fix the fealure test for windws
1 parent 454bc6d commit 57f22bf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

mermaid/_main.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ def _make_request_to_mermaid(self) -> None:
3030
self._diagram)
3131

3232
def to_svg(self, path: Union[str, Path]) -> None:
33-
with open(path, 'w') as file:
33+
with open(path, 'w', encoding='utf-8') as file:
3434
file.write(self.svg_response.text)
3535

3636
def to_png(self, path: Union[str, Path]) -> None:
37-
with open(path, 'w') as file:
37+
with open(path, 'w', encoding='utf-8') as file:
3838
file.write(self.img_response.text)

0 commit comments

Comments
 (0)