Fix parsing regex and stringifier for Todos

This commit is contained in:
2025-11-30 22:05:03 -05:00
parent 270ec59fbe
commit 597cf6fbb4
2 changed files with 4 additions and 3 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
import re
from todo import Todo
from .todo import Todo
TODO_PATTERN = r"^- \[( |X)\] (.+)$"
+2 -1
View File
@@ -8,4 +8,5 @@ class Todo:
self.lid = gen_random_base64(10)
def __str__(self):
return f"- [{self.checked}] {self.item}"
checkmark = "X" if self.checked else " "
return f"- [{checkmark}] {self.item}"