diff --git a/metrontagger/utils.py b/metrontagger/utils.py index d3c4364..700b991 100644 --- a/metrontagger/utils.py +++ b/metrontagger/utils.py @@ -16,8 +16,7 @@ def create_print_title(txt: str) -> str: Returns: str: The formatted title string, including newlines and dashes. """ - result = f"\n{txt}\n" - return result + "-" * len(txt) + return f"\n{txt}\n{txt.replace(txt, '-' * len(txt))}" def cleanup_string(path_name: int | str | None) -> str | None: