fix(application): exit after committing changes

This commit is contained in:
Nathaniel Landau
2023-01-22 19:53:23 +00:00
parent c427a987c1
commit 759fc3434f
4 changed files with 20 additions and 26 deletions

View File

@@ -350,11 +350,14 @@ class Note:
self.sub(current_frontmatter, new_frontmatter)
def write(self, path: Path | None = None) -> None:
def write(self, path: Path = None) -> None:
"""Writes the note's content to disk.
Args:
path (Path): Path to write the note to. Defaults to the note's path.
Raises:
typer.Exit: If the note's path is not found.
"""
p = self.note_path if path is None else path