diff --git a/src/main.rs b/src/main.rs index 06053b0..c86ef01 100644 --- a/src/main.rs +++ b/src/main.rs @@ -110,7 +110,7 @@ fn graphviz_export(tree: &TreeNode) -> String { fn tex_escape_str(s: &str) -> String { s.replace('_', "\\_") - .trim_start_matches('\n') + .trim_matches('\n') .replace("\n\n", "\n") .replace('\n', "\\newline\n") }